Ensure test client specifies max supply in unittest

This commit is contained in:
lash 2023-06-08 14:39:46 +01:00
parent 5ff686e513
commit 80589e574a
Signed by: lash
GPG Key ID: 21D2E7BB88C2A746
4 changed files with 7 additions and 5 deletions

View File

@ -16,4 +16,4 @@ class TestEthBurnerInterface:
self.rpc.do(o)
o = receipt(tx_hash)
r = self.rpc.do(o)
self.assertEqual(r['status'],1)
self.assertEqual(r['status'], 1)

View File

@ -31,7 +31,9 @@ class TestEthCapped(EthTesterCase):
txf = TxFactory(self.chain_spec, signer=self.signer, nonce_oracle=nonce_oracle)
tx = txf.template(self.accounts[0], None, use_nonce=True)
if getattr(self, 'max_supply_value', None) == None:
self.max_supply_value = 1024
enc = ABIContractEncoder()
enc.uint256(self.max_supply_value)
args = enc.get()

View File

@ -12,7 +12,7 @@ class TestEthCappedInterface:
self.max_supply_value = 0
def test_supply(self):
def test_default_supply(self):
if self.max_supply_value == 0:
return
c = EthCapped(self.chain_spec)
@ -25,7 +25,7 @@ class TestEthCappedInterface:
if self.set_method == None:
return
self.max_supply_value = 2048
self.max_supply_value *= 2
(tx_hash_hex, o) = self.set_method(self.address, self.accounts[0], self.max_supply_value)
self.rpc.do(o)
o = receipt(tx_hash_hex)

View File

@ -1,6 +1,6 @@
[metadata]
name = cic-contracts
version = 0.3.3
version = 0.3.4
description = CIC network smart contract interfaces
author = Louis Holbrook
author_email = dev@holbrook.no