switched out assertion library with should.js... I really should have written my own baby util library since that was the third time I've done that...

This commit is contained in:
Spencer Alger
2013-12-23 15:33:53 -07:00
parent 3d0b2fde4e
commit 2b3734a081
32 changed files with 828 additions and 987 deletions

View File

@ -1,7 +1,8 @@
var randomSelector = require('../../src/lib/selectors/random');
var _ = require('lodash');
describe('Random Selector', function () {
var randomSelector = require('../../src/lib/selectors/random');
var _ = require('lodash');
var expect = require('expect.js');
it('chooses a selection by random', function () {
var log = { a: 0, b: 0, c: 0 };
var choices = _.keys(log);
@ -11,9 +12,9 @@ describe('Random Selector', function () {
log[choice]++;
});
_.filter(log, function (count) {
expect(_.filter(log, function (count) {
return count < 200 || count > 400;
}).should.have.length(0);
})).to.have.length(0);
});
});