Overview
What is Latte?
Latte is a testing framework that simplifies the process of writing and running tests for your applications. It provides a user-friendly interface and powerful features to help you ensure the quality and reliability of your code. With Latte, you can easily create and manage test cases, run them with a single command, and generate detailed reports on test results. Whether you’re testing web applications, APIs, or any other type of software, Latte has you covered.
Core features:
- No need to import
it,test,describeorexpectin your test file. These functions are available globally. - Test
JavaScriptandTypeScriptcode at one time. - Asynchronous code testing.
- Global
DOMobject for testingHTML elements. - Built-in
coveragetool. Verboseor non verbose mode.Mockfunctions and objects.- Big set of built-in matchers.
- Extend
expectfunction with your own matchers. - Compatible with
codecovreport viewer. - A lot of expects in one test case.
- Setup and Teardown functions (
beforeEach,afterEach,beforeAll,afterAll). Watching modeandparalleltest executing.
Why?
While working on Metro UI and EasyQuery, there was a need to test code with support for DOM tests. Latte was created for these purposes.
Latte was created as a framework for general testing with DOM support and the ability to test entire HTML pages, but it can be used for any JavaScript/TypeScript project.