consterror=newError(`${options.transaction.finished} has been called on this transaction(${options.transaction.id}), you can no longer use it. (The rejected query is attached as the 'sql' property of this error)`);
@@ -124,16 +124,7 @@ if (current.dialect.supports.transactions) {
};
// Attention: this test is a bit racy. If you find a nicer way to test this: go ahead
returnSumSumSum.sync({force:true}).then(()=>{
returnexpect(Promise.join(transTest(80),transTest(80),transTest(80))).to.eventually.be.rejectedWith('could not serialize access due to read/write dependencies among transactions');
}).delay(100).then(()=>{
if(this.sequelize.test.$runningQueries!==0){
returnPromise.delay(200);
}
returnvoid0;
}).then(()=>{
if(this.sequelize.test.$runningQueries!==0){
returnPromise.delay(500);
}
returnexpect(Promise.all([transTest(80),transTest(80),transTest(80)])).to.eventually.be.rejectedWith('could not serialize access due to read/write dependencies among transactions');