You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since we moved away from the DB scenarios, the legibility and structure of unit tests has considerably degraded. This is particularly obvious in the db2/history/, actions and ingest/processors packages.
Some of the problems are:
We are mixing suites and normal tests
Fixtures are generated in a custom manner. Many tests have different approaches to generating them and there seem to be duplicated efforts across the tests. Good examples of this are effects_processor_test.go and transaction_operation_wrapper_test.go
There isn't a good alternative to the DB scenarios. There are are no libraries/helpers to easily inject fixture data into the database. This has led to a decrement of coverage in db2/history (see the history_claimable_balance* and history_liquidity_pool* code, for instance.
@bartekn suggests going through the test structure and designing a helper library, like we have for integration tests (e.g. for integration tests we have common functions to create accounts etc ... )
The text was updated successfully, but these errors were encountered:
Since we moved away from the DB scenarios, the legibility and structure of unit tests has considerably degraded. This is particularly obvious in the
db2/history/
,actions
andingest/processors
packages.Some of the problems are:
effects_processor_test.go
andtransaction_operation_wrapper_test.go
db2/history
(see thehistory_claimable_balance*
andhistory_liquidity_pool*
code, for instance.@bartekn suggests going through the test structure and designing a helper library, like we have for integration tests (e.g. for integration tests we have common functions to create accounts etc ... )
The text was updated successfully, but these errors were encountered: