Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add functionality to execute a user defined teardown after each test #28

Open
gianfra-t opened this issue Oct 9, 2023 · 6 comments
Open

Comments

@gianfra-t
Copy link
Contributor

As part of #26, the tokens used are now persistent in the standalone chain (or any chain used to test the contracts).

This introduces a different behavior and one must be aware when running tests that the tokens minted will persist after each run.
For this reason, some tests were modified in #26 to add a burn function before the minting, to ensure that the token balance starts at 0. (see this for example).

Proposed Enhancement

It would be interesting to have an analogous to the setUp function called teardown for example, that gets executed after each test suite runs no matter if the execution is successful or not.

@gianfra-t
Copy link
Contributor Author

@pendulum-chain/product The purpose of this ticket is to make a bit easier the writing and readability of tests. As of now it is completely possible to perform the same behavior just using the setUp function.

@prayagd
Copy link

prayagd commented Oct 10, 2023

Hey team! Please add your planning poker estimate with Zenhub @adelarja @b-yap @ebma @TorstenStueber

@prayagd
Copy link

prayagd commented Oct 10, 2023

Please add your planning poker estimate with Zenhub @gianfra-t

@prayagd
Copy link

prayagd commented Dec 7, 2023

@gianfra-t i assume this is nice to have right? If yes can i move this to icebox?

@gianfra-t
Copy link
Contributor Author

Yes it is a nice to have for the developer, not at all something that will add some extra capabilities.

@TorstenStueber
Copy link
Member

This should be quite doable and, as far as I understand, is more powerful than what forge provides.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants