-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
hasHook throws exception if specified hook doesn't exist #3181
Copy link
Copy link
Closed
Labels
type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type
Description
using 2.0.0-rc8
describe('#hasHook', function() {
describe('specified hook does not exist', function() {
it('should return true but throws an exception (BUG ???)', function(done) {
var Model = sequelize.define('Model', {
name: Sequelize.STRING
});
try {
var result = Model.hasHook('beforeCreate');
// Never get to here...
expect(result).to.be.false;
done();
} catch (error) {
done(error);
}
});
});
});Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type