Moved test setup into beforeEach