Remove unncessary beforeAfter in jest, store was re-created for every test

This commit is contained in:
Jason Zhu 2023-03-26 20:09:58 +11:00
parent 4db65c6375
commit 6aa1baa5fd

View File

@ -18,10 +18,6 @@ describe('pokedexApi', () => {
});
});
afterEach(() => {
store.dispatch(pokedexApi.util.resetApiState());
});
describe('JEST test against real API', () => {
test('visit https://pokeapi.co/api/v2/region/1 should return correct data', async () => {
await store.dispatch(pokedexApi.endpoints.getRegion.initiate(1));