Aug 25, 2017 · 1 min read
`Functions like `beforeEach` and `afterEach` actively encourage you to do something you definitely should not do: Share state between tests. Vs. Tape: No such functions for global state sharing. Instead, call setup and teardown routines from individual tests, and contain all state to local test variables.` <- These are setup and teardown functions. It’s cleaner not to duplicate setup/teardown code or it’s invocation in every test for common state in context-based test scenarios. That’s not global state, it’s clean code
