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

Commit a3fe500

Browse files
fix
1 parent cb22abe commit a3fe500

File tree

1 file changed

+13
-16
lines changed

1 file changed

+13
-16
lines changed

test/api/bitswap.spec.js

+13-16
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,13 @@ describe('.bitswap', () => {
1818
it('.stat', (done) => {
1919
apiClients.a.bitswap.stat((err, res) => {
2020
expect(err).to.not.exist
21-
expect(res).to.have.to.be.eql({
22-
BlocksReceived: 0,
23-
DupBlksReceived: 0,
24-
DupDataReceived: 0,
25-
Peers: null,
26-
ProvideBufLen: 0,
27-
Wantlist: null
28-
})
21+
expect(res).to.have.property('BlocksReceived')
22+
expect(res).to.have.property('DupBlksReceived')
23+
expect(res).to.have.property('DupDataReceived')
24+
expect(res).to.have.property('Peers')
25+
expect(res).to.have.property('ProvideBufLen')
26+
expect(res).to.have.property('Wantlist')
27+
2928
done()
3029
})
3130
})
@@ -51,14 +50,12 @@ describe('.bitswap', () => {
5150
it('.stat', () => {
5251
return apiClients.a.bitswap.stat()
5352
.then((res) => {
54-
expect(res).to.have.to.be.eql({
55-
BlocksReceived: 0,
56-
DupBlksReceived: 0,
57-
DupDataReceived: 0,
58-
Peers: null,
59-
ProvideBufLen: 0,
60-
Wantlist: null
61-
})
53+
expect(res).to.have.property('BlocksReceived')
54+
expect(res).to.have.property('DupBlksReceived')
55+
expect(res).to.have.property('DupDataReceived')
56+
expect(res).to.have.property('Peers')
57+
expect(res).to.have.property('ProvideBufLen')
58+
expect(res).to.have.property('Wantlist')
6259
})
6360
})
6461

0 commit comments

Comments
 (0)