Skip to content

GuiltyDolphin/dentest

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dentest

Testing framework for Deno.

Usage

Dentest provides support for grouping tests using testGroup. Only top-level tests need to be run using the runAsMain method. The following example shows how to group tests in this manner:

import {
    assertEquals,
    testGroup,
    Test
} from 'https://deno.land/x/dentest/mod.ts'

testGroup('booleans',
    new Test('true is true', () => assertEquals(true, true)),
    new Test('false is false', () => assertEquals(false, false)),
    testGroup('more boolean tests',
        new Test('not true is false', () => assertEquals(!true, false)),
        new Test('not false is true', () => assertEquals(!false, true)),
    ),
).runAsMain();

Development

Coverage

To generate code test coverage, make sure you have access to the genhtml tool (e.g., via the lcov package on AUR), then run make coverage in the top-level of the project.

Testing

Run make test in the top-level of the project to run the tests. If you need to see results for tests that passed, run make test_verbose or deno test instead.

About

Testing framework for Deno

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors