Skip to content
generation-2
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

assertron

Run assertions against your objects. Define contracts with a handy DSL. Test your code inline.

Travis build status Code Climate Test Coverage Dependency Status devDependency Status

Idea

Assertron lets you run assertions against objects via a convenient DSL:

import {assert as A} from 'assertron';

function myFunc(foo, bar) {
  A(foo, {object: true});

  A(bar, {
    optional: true,
    or: {
      number: {
        min: 3,
        max: 10,
        orString: true
      },
      function: true
    }
  })


  /* Your function's code here */
}

About

Run assertions against your objects. Define contracts with a handy DSL. Test your code inline.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published