Skip to content

Commit

Permalink
chore: fix flow errors (#330)
Browse files Browse the repository at this point in the history
  • Loading branch information
SimenB authored Feb 2, 2023
1 parent c163aa9 commit ff69d98
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/__tests__/dataloader.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -435,12 +435,12 @@ describe('Primary API', () => {
});

it('allows giving the loader a name', () => {
expect(new DataLoader(() => []).name).toBeNull();
expect(new DataLoader(() => [], {}).name).toBeNull();
expect(new DataLoader(() => Promise.resolve([])).name).toBeNull();
expect(new DataLoader(() => Promise.resolve([]), {}).name).toBeNull();

expect(new DataLoader(() => [], { name: 'Some name' }).name).toBe(
'Some name',
);
expect(
new DataLoader(() => Promise.resolve([]), { name: 'Some name' }).name,
).toBe('Some name');
});
});

Expand Down

0 comments on commit ff69d98

Please sign in to comment.