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

[Changed] Reset config to burrito's default between tests #95

Closed
wants to merge 9 commits into from

Conversation

Perizote
Copy link
Contributor

@Perizote Perizote commented Aug 4, 2021

🎩 What?

Reset config to burrito's default between tests

🤔 Why?

So that this issue gets closed.
We have seen in the past how not doing a reset of the config to what burrito knows as default have caused inconsistent behaviour. I believe @juandiegombr and @maurogestoso have experienced this issue as well when playing with the configuration of the history. Doing a reset of the config between tests just before jest executes its loop to apply the default config we've set per project should do the trick.

🧪 How has this been tested? / 💥 How will I know if this breaks?

Added a test that checks that the config is the burrito's default even tho it is the last test of the suite. To be honest, I don't like this test because tests shouldn't be aware of the order they are being executed and so executing it the first of the suite would make it pass without having to change the code 🤷‍♂️ .
A few other tests from other suites had been updated because they were passing just because the config wasn't being reset.

🗣️ Comments

We were actually doing something similar in one of our tests as a helper. Now we can get rid of it and works globally.

@Perizote Perizote requested a review from a team as a code owner August 4, 2021 12:30
@Perizote Perizote linked an issue Aug 4, 2021 that may be closed by this pull request
@Perizote
Copy link
Contributor Author

Perizote commented Aug 5, 2021

I'm closing this PR because it solves a problem that we didn't really understood. Now that we have more info I'm gonna update the issue so that it gives more context.

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

Successfully merging this pull request may close these issues.

Reset config to default between tests
2 participants