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
If you run integration tests on a local system multiple times in a row (for example in order to test them), always the same setup is used ( temp\test-iobroker.adatername ). If you do not clean up the temp directory manually, iobroker and also the db-files will be reused on the next test run.
This leads to the situation that database changes from the last integration test persist between multiple test runs (and may interfere with them). So I vote for an after() clause that restores the backup that is already done during start. Or move the restore of the backup into "afterEach".
Maybe the restore in "afterEach" is even better, because currently the first restore is not necessary, if I understand it correctly.
The text was updated successfully, but these errors were encountered:
I agree. One thing to keep in mind: We need to be able to restore the original database in case the tests crashed - so maybe store that state in a separate file.
If you run integration tests on a local system multiple times in a row (for example in order to test them), always the same setup is used ( temp\test-iobroker.adatername ). If you do not clean up the temp directory manually, iobroker and also the db-files will be reused on the next test run.
This leads to the situation that database changes from the last integration test persist between multiple test runs (and may interfere with them). So I vote for an after() clause that restores the backup that is already done during start. Or move the restore of the backup into "afterEach".
Maybe the restore in "afterEach" is even better, because currently the first restore is not necessary, if I understand it correctly.
The text was updated successfully, but these errors were encountered: