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)`);
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) {
...
@@ -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
// Attention: this test is a bit racy. If you find a nicer way to test this: go ahead
returnSumSumSum.sync({force:true}).then(()=>{
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');
returnexpect(Promise.all([transTest(80),transTest(80),transTest(80)])).to.eventually.be.rejectedWith('could not serialize access due to read/write dependencies among transactions');