Files
openzeppelin-contracts/test/token/ERC20/BurnableToken.test.js
Santiago Palladino 0926729c8f Add StandardBurnableToken implementation (#870)
* Add StandardBurnableToken implementation

BurnableToken that extends from StandardToken and adds a
burnFrom method that decrements allowance. Equivalent to
a transferFrom plus burn in a single operation.

* Return event object from expectEvent helper

* Add comment on Approval event in burnFrom function

* Improvements on burnable token tests

- Inject initial balance as a parameter to the behaviour
- Use expectEvent helper for assertions on events
- Use chai bignumber for numbers
- Change to bdd-style assertions
2018-04-11 16:15:33 -03:00

13 lines
388 B
JavaScript

import shouldBehaveLikeBurnableToken from './BurnableToken.behaviour';
const BurnableTokenMock = artifacts.require('BurnableTokenMock');
contract('BurnableToken', function ([owner]) {
const initialBalance = 1000;
beforeEach(async function () {
this.token = await BurnableTokenMock.new(owner, initialBalance);
});
shouldBehaveLikeBurnableToken([owner], initialBalance);
});