omgnetwork / plasma-mvp

OmiseGO's research implementation of Minimal Viable Plasma
MIT License
561 stars 158 forks source link

Refactor tests so contracts are only compiled once #104

Closed smartcontracts closed 6 years ago

smartcontracts commented 6 years ago

One of our pytest fixtures, get_contract, compiles the specified contract, deploys it, and returns an ethereum.tools.tester.ABIContract instance:

https://github.com/omisego/plasma-mvp/blob/569e880178d20e589b35161e305c7e698e48129b/tests/conftest.py#L49-L58

This slows down our unit tests a lot and could easily be improved by compiling the contracts only once (at the start of the tests).