state of the art beforeEach snippet