mirror of openzeppelin-contracts
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
openzeppelin-contracts/test/helpers/assertJump.js

15 lines
333 B

const should = require('chai')
.should();
async function assertJump (promise) {
try {
await promise;
should.fail('Expected invalid opcode not received');
} catch (error) {
error.message.should.include('invalid opcode', `Expected "invalid opcode", got ${error} instead`);
}
}
module.exports = {
assertJump,
};