Commit Graph

2 Commits

Author SHA1 Message Date
Ben Thorner
9c983b8941 Restore all mocked values after tests
In response to [1].

This prevents mocked values leaking between tests [2]. I did try to
set 'mockRestore: true' in jest.config, but that means the restore
happens before _every_ test, which isn't what we want.

[1]: https://github.com/alphagov/notifications-admin/pull/3878#discussion_r631060116
[2]: https://jestjs.io/docs/jest-object#jestrestoreallmocks
2021-05-13 10:22:28 +01:00
Tom Byers
0131f0c1b1 Move setup/teardown out of tests 2019-06-12 16:03:18 +01:00