diff --git a/test/validations.test.js b/test/validations.test.js index 082ee617..d48984b8 100644 --- a/test/validations.test.js +++ b/test/validations.test.js @@ -305,6 +305,20 @@ describe('validations', function() { describe('custom', function() { it('should validate using custom sync validation'); - it('should validate using custom async validation'); + + describe('async', function() { + it('should validate using custom async', function(done) { + User.validateAsync('countryCode', function(errCb, cb) { + setImmediate(function() { + errCb(); + }); + }); + var u = new User(getValidAttributes()); + u.isValid(function(valid) { + valid.should.be.false; + done(); + }); + }); + }); }); });