Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tunnckoCore committed Oct 11, 2015
1 parent bc1e0d1 commit 86891f1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,21 @@ function alwaysDone (val) {
}

test('should accept string and handle it from `.then`', function (done) {
alwaysDone('foo bar baz').then(function (res) {
lettaValue('foo bar baz').then(function (res) {
test.strictEqual(res, 'foo bar baz')
done()
}, done)
})

test('should accept array and handle it from `.then`', function (done) {
alwaysDone(['foo', 'bar', 'baz']).then(function (res) {
lettaValue(['foo', 'bar', 'baz']).then(function (res) {
test.deepEqual(res, ['foo', 'bar', 'baz'])
done()
}, done)
})

test('should accept Error instance and catch it from `.catch`', function (done) {
alwaysDone(new Error('foo err')).catch(function (err) {
lettaValue(new Error('foo err')).catch(function (err) {
test.strictEqual(err.message, 'foo err')
done()
})
Expand Down

0 comments on commit 86891f1

Please sign in to comment.