2.0.2 • Published 7 years ago

joe v2.0.2

Weekly downloads
156
License
MIT
Repository
github
Last release
7 years ago

Joe

Build Status NPM version NPM downloads Dependency Status Dev Dependency Status Gratipay donate button Flattr donate button PayPayl donate button BitCoin donate button Wishlist browse button

Joe is a JavaScript testing framework that actually works. Unlike Mocha, we won't die on you abruptly when executing dynamically created tests and are always able to associate the correct test to the correct corresponding test suite. Switching from Mocha is trivial and only takes a few minutes.

Install

NPM

  • Use: require('joe')
  • Install: npm install --save joe

Browserify

  • Use: require('joe')
  • Install: npm install --save joe
  • CDN URL: //wzrd.in/bundle/joe@1.6.1

Ender

  • Use: require('joe')
  • Install: ender add joe

Usage

Example

// define your test suite
require('joe').describe('suite name', function(describe,it){
	// group together items into sub suites if you desire
	describe('sub suite name', function(describe,it){
		// create both synchronous and asynchronous tests
		it('synchronous test', function(){
			// do your stuff
		});
		it('asynchronous test name', function(complete){
			setTimeout(function(){
				// do your stuff
				complete();
			},500);
		});
		// run a methods before and\or after the test
		function beforeEach(test) {
			// do some pre test stuff
		}
		function afterEach(test, err) {
			// do some post test stuff
		}
		it('before and after options test', {before: beforeEach, after: afterEach}, function(){
			// do your stuff
		});
	});
	// you can also define tests dynamically when using the completion callback on the group
	describe('lets create dynamic tests', function(describe,it,done){
		setTimeout(function(){
			it('a synchronous dynamic test',function(){
				// do your stuff
			});
			done();
		},500)
	});
});
$ node example.js 
suite name
suite name ➞  sub suite name
suite name ➞  sub suite name ➞  synchronous test
suite name ➞  sub suite name ➞  synchronous test ✔   
suite name ➞  sub suite name ➞  asynchronous test name
suite name ➞  sub suite name ➞  asynchronous test name ✔   
suite name ➞  sub suite name ✔  
suite name ➞  lets create dynamic tests
suite name ➞  lets create dynamic tests ➞  a synchronous dynamic test
suite name ➞  lets create dynamic tests ➞  a synchronous dynamic test ✔   
suite name ➞  lets create dynamic tests ✔  
suite name ✔  

3/3 tests ran successfully, everything passed

Complete Documentation

View the Complete Joe Documentation on the Bevry Website

Custom Reporters

Discover the available Custom Reporters for Joe using the joe-reporter keyword on the NPM Registry

History

Discover the change history by heading on over to the HISTORY.md file.

Contribute

Discover how you can contribute by heading on over to the CONTRIBUTING.md file.

Backers

Maintainers

These amazing people are maintaining this project:

Sponsors

No sponsors yet! Will you be the first?

Gratipay donate button Flattr donate button PayPayl donate button BitCoin donate button Wishlist browse button

Contributors

These amazing people have contributed code to this project:

Become a contributor!

License

Licensed under the incredibly permissive MIT license

Copyright © 2012+ Bevry Pty Ltd us@bevry.me (http://bevry.me)

1.6.1

7 years ago

2.0.2

8 years ago

2.0.1

8 years ago

2.0.0

8 years ago

1.8.0

8 years ago

1.7.0

8 years ago

1.6.0

9 years ago

1.5.0

10 years ago

1.4.0

10 years ago

1.3.3

10 years ago

1.3.2

11 years ago

1.3.1

11 years ago

1.3.0

11 years ago

1.2.0

11 years ago

1.1.2

11 years ago

1.1.1

11 years ago

1.1.0

12 years ago

1.0.3

12 years ago

1.0.2

12 years ago

1.0.1

12 years ago

1.0.0

12 years ago

0.4.0

12 years ago

0.3.4

12 years ago

0.3.3

12 years ago

0.3.2

12 years ago

0.3.1

12 years ago

0.3.0

12 years ago

0.2.1

12 years ago

0.2.0

12 years ago

0.1.0

12 years ago