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

Commit bbb8c8c9 by Sascha Depold

pass a sequelize instance

1 parent aa827b54
Showing with 3 additions and 3 deletions
...@@ -6,12 +6,12 @@ var chai = require('chai') ...@@ -6,12 +6,12 @@ var chai = require('chai')
describe(Support.getTestDialectTeaser("Transaction"), function () { describe(Support.getTestDialectTeaser("Transaction"), function () {
describe('constructor', function() { describe('constructor', function() {
it('stores options', function() { it('stores options', function() {
var transaction = new Transaction() var transaction = new Transaction(this.sequelize)
expect(transaction.options).to.be.an.instanceOf(Object) expect(transaction.options).to.be.an.instanceOf(Object)
}) })
it('generates an identifier', function() { it('generates an identifier', function() {
var transaction = new Transaction() var transaction = new Transaction(this.sequelize)
expect(transaction.id).to.exist expect(transaction.id).to.exist
}) })
}) })
...@@ -30,7 +30,7 @@ describe(Support.getTestDialectTeaser("Transaction"), function () { ...@@ -30,7 +30,7 @@ describe(Support.getTestDialectTeaser("Transaction"), function () {
describe('done', function() { describe('done', function() {
it('gets called when the transaction gets commited', function(done) { it('gets called when the transaction gets commited', function(done) {
var transaction = new Transaction() var transaction = new Transaction(this.sequelize)
transaction.done(done) transaction.done(done)
transaction.commit() transaction.commit()
}) })
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!