Skip to content

Commit

Permalink
undo unnecessary changes to one test
Browse files Browse the repository at this point in the history
  • Loading branch information
chrispader committed Jun 11, 2024
1 parent 7165f1c commit 1a983e5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/unit/useOnyxTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,13 +98,13 @@ describe('useOnyx', () => {
});

it('should initially return null while loading non-cached key, and then return value and loaded state', async () => {
await StorageMock.setItem(ONYXKEYS.TEST_KEY, 'test');

const {result} = renderHook(() => useOnyx(ONYXKEYS.TEST_KEY));

expect(result.current[0]).toBeUndefined();
expect(result.current[1].status).toEqual('loading');

await StorageMock.setItem(ONYXKEYS.TEST_KEY, 'test');

await act(async () => waitForPromisesToResolve());

expect(result.current[0]).toEqual('test');
Expand Down

0 comments on commit 1a983e5

Please sign in to comment.