Files
openzeppelin-contracts/test/token/ERC20/RBACCappedToken.test.js
Nicolás Venturo cea2a85a42 Remove Babel (#1074)
* Test helpers no longer rely on Babel.

* Behaviours are no longer imported.

* Removed Babel dependency.

* Fixed linter errors.
2018-07-18 19:37:16 -03:00

20 lines
857 B
JavaScript

const { ether } = require('../../helpers/ether');
const { shouldBehaveLikeRBACMintableToken } = require('./RBACMintableToken.behaviour');
const { shouldBehaveLikeMintableToken } = require('./MintableToken.behaviour');
const { shouldBehaveLikeCappedToken } = require('./CappedToken.behaviour');
const RBACCappedTokenMock = artifacts.require('RBACCappedTokenMock');
contract('RBACCappedToken', function ([owner, anotherAccount, minter]) {
const _cap = ether(1000);
beforeEach(async function () {
this.token = await RBACCappedTokenMock.new(_cap, { from: owner });
await this.token.addMinter(minter, { from: owner });
});
shouldBehaveLikeMintableToken([owner, anotherAccount, minter]);
shouldBehaveLikeRBACMintableToken([owner, anotherAccount]);
shouldBehaveLikeCappedToken([owner, anotherAccount, minter, _cap]);
});