Skip to content

Commit beae475

Browse files
committed
Minor simplification in useGraphQL tests.
1 parent 966ca31 commit beae475

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
- Removed `package-lock.json` from `.gitignore` and `.prettierignore` as it’s disabled in `.npmrc` anyway.
1717
- Removed redundant ESLint ignore comments.
1818
- Use GitHub Actions instead of Travis for CI.
19+
- Minor simplification in `useGraphQL` tests.
1920
- Documentation improvements, fixing [#35](https://github.com/jaydenseric/graphql-react/issues/35):
2021
- Updated the project description with better phrasing that includes the bundle size.
2122
- Moved the readme “Apollo comparison” section to the end, and updated the “Bundle impact” subsection for the new Apollo React hooks API.

src/test/useGraphQL.mjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ t.test('useGraphQL()', async t => {
4242
const { cache } = graphql
4343

4444
// eslint-disable-next-line react/prop-types
45-
const Component = ({ loadOnMount, ...operationOptions }) => {
46-
const result = useGraphQL({ loadOnMount, ...operationOptions })
45+
const Component = operationOptions => {
46+
const result = useGraphQL(operationOptions)
4747
return JSON.stringify(result)
4848
}
4949

0 commit comments

Comments
 (0)