Skip to content
This repository has been archived by the owner on Mar 10, 2020. It is now read-only.

Replace assert with chai #153

Merged
merged 3 commits into from
Nov 28, 2015
Merged

Replace assert with chai #153

merged 3 commits into from
Nov 28, 2015

Conversation

dignifiedquire
Copy link
Contributor

  •  Fix bug in dht that this exposes

@dignifiedquire dignifiedquire changed the title [WIP] tests: Start work on moving to chai Replace assert with chai Nov 27, 2015
@@ -4,29 +4,26 @@ describe('.dht', () => {
it('returns an error when getting a non-existent key from the DHT',
done => {
apiClients['a'].dht.get('non-existent', {timeout: '100ms'}, (err, value) => {
assert(err)
console.log(err, value)
expect(err).to.be.an.instanceof(Error)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe the test fails because the err passed is not in fact an Error object, but just some message.

@daviddias daviddias mentioned this pull request Nov 28, 2015
42 tasks
@dignifiedquire
Copy link
Contributor Author

LGTM thanks @diasdavid

daviddias added a commit that referenced this pull request Nov 28, 2015
Replace assert with chai
@daviddias daviddias merged commit 6414e66 into master Nov 28, 2015
@daviddias daviddias deleted the chai branch November 28, 2015 18:59
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants