feat: apply eslint --fix across project
This commit is contained in:
@ -1,17 +1,16 @@
|
||||
const assertRevert = require('./helpers/assertRevert');
|
||||
|
||||
var BasicTokenMock = artifacts.require("./helpers/BasicTokenMock.sol");
|
||||
var BasicTokenMock = artifacts.require('./helpers/BasicTokenMock.sol');
|
||||
|
||||
contract('BasicToken', function(accounts) {
|
||||
|
||||
it("should return the correct totalSupply after construction", async function() {
|
||||
contract('BasicToken', function (accounts) {
|
||||
it('should return the correct totalSupply after construction', async function () {
|
||||
let token = await BasicTokenMock.new(accounts[0], 100);
|
||||
let totalSupply = await token.totalSupply();
|
||||
|
||||
assert.equal(totalSupply, 100);
|
||||
})
|
||||
});
|
||||
|
||||
it("should return correct balances after transfer", async function(){
|
||||
it('should return correct balances after transfer', async function () {
|
||||
let token = await BasicTokenMock.new(accounts[0], 100);
|
||||
let transfer = await token.transfer(accounts[1], 100);
|
||||
|
||||
@ -22,24 +21,23 @@ contract('BasicToken', function(accounts) {
|
||||
assert.equal(secondAccountBalance, 100);
|
||||
});
|
||||
|
||||
it('should throw an error when trying to transfer more than balance', async function() {
|
||||
it('should throw an error when trying to transfer more than balance', async function () {
|
||||
let token = await BasicTokenMock.new(accounts[0], 100);
|
||||
try {
|
||||
let transfer = await token.transfer(accounts[1], 101);
|
||||
assert.fail('should have thrown before');
|
||||
} catch(error) {
|
||||
} catch (error) {
|
||||
assertRevert(error);
|
||||
}
|
||||
});
|
||||
|
||||
it('should throw an error when trying to transfer to 0x0', async function() {
|
||||
it('should throw an error when trying to transfer to 0x0', async function () {
|
||||
let token = await BasicTokenMock.new(accounts[0], 100);
|
||||
try {
|
||||
let transfer = await token.transfer(0x0, 100);
|
||||
assert.fail('should have thrown before');
|
||||
} catch(error) {
|
||||
} catch (error) {
|
||||
assertRevert(error);
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user