Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/theremotecoder/unit-testing-playground

TDD + BDD testing + tools - Playground + Experiments
https://github.com/theremotecoder/unit-testing-playground

bdd es6 javascript javascript-testing javascript-tests javascript-unit-test jest jest-test jest-testing jest-tests js node tdd testing testing-library unit-test unit-testing unittest unittesting unittests-generation

Last synced: 4 days ago
JSON representation

TDD + BDD testing + tools - Playground + Experiments

Awesome Lists containing this project

README

        

## Unit Testing

## 5 Step Method

1. Decide tiny aspects and limitations (data requirements, responsibilities)
2. Define input/output of aspects (data types, structures, results)
3. Define function signatures (parameters, variants)
4. Define test case for tiny aspects (including misuse and expected fails)
5. Write code

## JEST API

```txt
toStrictEqual // Type + Structure
toBe // Prim itives, References
toEqual // Deep/Recursive object equality
toBeTruthy //
toBeFalsy //
toBeCloseTo // Float
```