marnett / ethereum

0 stars 0 forks source link

Use simpler tester "ABI" notation #23

Closed amiller closed 9 years ago

amiller commented 9 years ago

There's simpler syntax you can use for the tester, that avoids a lot of the weird encode/decode noise.

For example here's a better simpler example for the namecoin test:

s = tester.state()
c = s.abi_contract(serpent_code)
o = c.register("Bob", 10)
print(o)

Here's another example: https://github.com/ethereum/pyethereum/blob/develop/ethereum/tests/test_contracts.py#L895

I guess it's Okay if what we have works, but reducing the noise might make people happier using it.

marnett commented 9 years ago

what we have works, but we can definitely look into changing it for simplicity's sake.

firesnowball commented 9 years ago

I'm going to try testing it in some of the simpler examples (namecoin, bank, etc.) since I need to add comments anyway