Created
October 14, 2017 14:34
-
-
Save scott-w/f3d92b8f660df6c4d65efaf71aa6562c to your computer and use it in GitHub Desktop.
New Failing Tests
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { assert } from 'chai'; | |
import { MyModel } from 'model'; | |
describe('MyModel', function() { | |
let model = null | |
afterEach(function() { | |
model = null; | |
}); | |
describe('initalized empty', function() { | |
beforeEach(function() { | |
model = new MyModel(); | |
}); | |
it('defaults its counter to 0', function() { | |
assert.equal(model.get('counter'), 0); | |
}); | |
describe('calling increment()', function() { | |
it('increments by 1', function() { | |
model.increment(); | |
assert.equal(model.get('counter'), 1); | |
}); | |
it('returns the incremented value', function() { | |
assert.equal(model.increment(), 1); | |
}); | |
}); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment