不要怂,就是干,撸起袖子干!

Commit f862ca78 by Sascha Depold

fuu

1 parent d58cd408
Showing with 15 additions and 13 deletions
...@@ -6,7 +6,7 @@ if (typeof require === 'function') { ...@@ -6,7 +6,7 @@ if (typeof require === 'function') {
} }
buster.spec.expose() buster.spec.expose()
buster.testRunner.timeout = 500 buster.testRunner.timeout = 1500
describe("[" + dialect.toUpperCase() + "] HasOne", function() { describe("[" + dialect.toUpperCase() + "] HasOne", function() {
before(function(done) { before(function(done) {
...@@ -27,23 +27,25 @@ describe("[" + dialect.toUpperCase() + "] HasOne", function() { ...@@ -27,23 +27,25 @@ describe("[" + dialect.toUpperCase() + "] HasOne", function() {
User.hasOne(Task) User.hasOne(Task)
this.sequelize.sync({ force: true }).success(function() { this.sequelize.sync({ force: true }).success(function() {
User.create({ username: 'foo' }).success(function(user) { setTimeout(function(){
Task.create({ title: 'task' }).success(function(task) { User.create({ username: 'foo' }).success(function(user) {
user.setTask(task).success(function() { Task.create({ title: 'task' }).success(function(task) {
user.getTask().success(function(task) { user.setTask(task).success(function() {
expect(task).not.toEqual(null) user.getTask().success(function(task) {
expect(task).not.toEqual(null)
user.setTask(null).success(function() {
user.getTask().success(function(task) { user.setTask(null).success(function() {
expect(task).toEqual(null) user.getTask().success(function(task) {
done() expect(task).toEqual(null)
done()
})
}) })
})
})
}) })
}) })
}) })
}) }.bind(this), 500)
}) })
}) })
}) })
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!