Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integration tests #4

Merged
merged 2 commits into from
Sep 14, 2022
Merged

Integration tests #4

merged 2 commits into from
Sep 14, 2022

Conversation

anthonyhastings
Copy link
Owner

@anthonyhastings anthonyhastings commented Aug 1, 2022

  • Adding start-apollo-server-test command to run a removable container for running tests.
  • Adding server/tsconfig.build.json specifically for building assets (this config ignores test related files). The original tsconfig.json can be used for type-checking and apply to all files.
  • Updating server/src/server.mts to expose the server as well as the start/listen method; this allows us to use the server within tests without actually binding it to a port.
  • Adding jest and ts-jest packages to run typescript files in Jest.
  • Adding npm scripts to run tests in ESM mode and build artifacts beforehand.
  • Adding tests for Buyer and Order queries and mutations; they stub the data source class and return responses accordingly.

More Information:

@anthonyhastings anthonyhastings force-pushed the integration-tests branch 9 times, most recently from 5f318a4 to 58d25a5 Compare September 14, 2022 17:30
@anthonyhastings anthonyhastings self-assigned this Sep 14, 2022
@anthonyhastings anthonyhastings marked this pull request as ready for review September 14, 2022 19:33
@anthonyhastings anthonyhastings merged commit 2aa2e01 into main Sep 14, 2022
@delete-merged-branch delete-merged-branch bot deleted the integration-tests branch September 14, 2022 19:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant