use to.have.lengthOf
This commit is contained in:
parent
1e69d2d1e1
commit
4d63a4d02a
@ -31,12 +31,12 @@ describe('TokenRegistryWrapper', () => {
|
||||
describe('#getTokensAsync', () => {
|
||||
it('should return all the tokens added to the tokenRegistry during the migration', async () => {
|
||||
const tokens = await zeroEx.tokenRegistry.getTokensAsync();
|
||||
expect(tokens.length).to.be.equal(TOKEN_REGISTRY_SIZE_AFTER_MIGRATION);
|
||||
expect(tokens).to.have.lengthOf(TOKEN_REGISTRY_SIZE_AFTER_MIGRATION);
|
||||
|
||||
const schemaValidator = new SchemaValidator();
|
||||
_.each(tokens, token => {
|
||||
const validationResult = schemaValidator.validate(token, tokenSchema);
|
||||
expect(validationResult.errors.length).to.be.equal(0);
|
||||
expect(validationResult.errors).to.have.lengthOf(0);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user