Fix warnings
This commit is contained in:
parent
cd32dffc73
commit
310b06dfe8
|
@ -1,3 +1,5 @@
|
||||||
switch("path", "..")
|
switch("path", "..")
|
||||||
when (NimMajor, NimMinor) >= (1, 4):
|
when (NimMajor, NimMinor) >= (1, 4):
|
||||||
switch("hint", "XCannotRaiseY:off")
|
switch("hint", "XCannotRaiseY:off")
|
||||||
|
when (NimMajor, NimMinor, NimPatch) >= (1, 6, 11):
|
||||||
|
switch("warning", "BareExcept:off")
|
||||||
|
|
|
@ -46,7 +46,7 @@ template subscriptionTests(subscriptions, client) =
|
||||||
var count = 0
|
var count = 0
|
||||||
proc callback(blck: Block) =
|
proc callback(blck: Block) =
|
||||||
inc count
|
inc count
|
||||||
let subscription = await subscriptions.subscribeBlocks(callback)
|
discard await subscriptions.subscribeBlocks(callback)
|
||||||
discard await client.call("evm_mine", newJArray())
|
discard await client.call("evm_mine", newJArray())
|
||||||
check eventually count > 0
|
check eventually count > 0
|
||||||
await subscriptions.close()
|
await subscriptions.close()
|
||||||
|
|
|
@ -13,7 +13,7 @@ type
|
||||||
TestToken = ref object of Erc20Token
|
TestToken = ref object of Erc20Token
|
||||||
|
|
||||||
method mint(token: TestToken, holder: Address, amount: UInt256): ?TransactionResponse {.base, contract.}
|
method mint(token: TestToken, holder: Address, amount: UInt256): ?TransactionResponse {.base, contract.}
|
||||||
method myBalance(token: TestToken): UInt256 {.contract, view.}
|
method myBalance(token: TestToken): UInt256 {.base, contract, view.}
|
||||||
|
|
||||||
for url in ["ws://localhost:8545", "http://localhost:8545"]:
|
for url in ["ws://localhost:8545", "http://localhost:8545"]:
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,6 @@ import pkg/stint
|
||||||
import pkg/ethers
|
import pkg/ethers
|
||||||
import pkg/ethers/erc20
|
import pkg/ethers/erc20
|
||||||
import ./hardhat
|
import ./hardhat
|
||||||
import ./miner
|
|
||||||
import ./mocks
|
|
||||||
|
|
||||||
type
|
type
|
||||||
TestToken = ref object of Erc20Token
|
TestToken = ref object of Erc20Token
|
||||||
|
@ -17,7 +15,7 @@ for url in ["ws://localhost:8545", "http://localhost:8545"]:
|
||||||
|
|
||||||
suite "ERC20 (" & url & ")":
|
suite "ERC20 (" & url & ")":
|
||||||
|
|
||||||
var token, token1: Erc20Token
|
var token: Erc20Token
|
||||||
var testToken: TestToken
|
var testToken: TestToken
|
||||||
var provider: JsonRpcProvider
|
var provider: JsonRpcProvider
|
||||||
var snapshot: JsonNode
|
var snapshot: JsonNode
|
||||||
|
|
Loading…
Reference in New Issue