The main purpose of this PR is to improve the assertion methods and to make them more
discoverable by exposing them directly on the Promise returned by
sendAndConfirmTransaction.
Transaction Handler Asserts
The following methods are exposed:
assertSuccess
assertError
assertLogs
Either of the above have to be synchronously called on the returned Promise or an error is
raised.
This allowed us to default skipPreflight: true since now errors don't fall through the cracks
like as they potentially did before when that setting was used and we did not check that
asserts were performed on the results.
assertNone allows to bypass this behavior.
Transaction Checker Asserts
For cases where the amman transaction handler cannot be used a TransactionChecker is provided
in order to allow performing the same asserts via the transaction signature.
Misc
Browser Support
First attempt at making amman usable in the browser, not sufficient at this point.
Relay
Fixed emitter leak by tracking account subs
Fetched Accounts
Only creating accounts folder if we have some accounts to fetch.
Config
Fixed extending config which had broken account resolvers.
Summary
The main purpose of this PR is to improve the assertion methods and to make them more discoverable by exposing them directly on the
Promise
returned bysendAndConfirmTransaction
.Transaction Handler Asserts
The following methods are exposed:
assertSuccess
assertError
assertLogs
Either of the above have to be synchronously called on the returned
Promise
or an error is raised. This allowed us to defaultskipPreflight: true
since now errors don't fall through the cracks like as they potentially did before when that setting was used and we did not check that asserts were performed on the results.assertNone
allows to bypass this behavior.Transaction Checker Asserts
For cases where the amman transaction handler cannot be used a
TransactionChecker
is provided in order to allow performing the same asserts via the transaction signature.Misc
Browser Support
First attempt at making amman usable in the browser, not sufficient at this point.
Relay
Fixed emitter leak by tracking account subs
Fetched Accounts
Only creating accounts folder if we have some accounts to fetch.
Config
Fixed extending config which had broken account resolvers.