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

58 refactor reveaal and user endpoint tests #63

Merged
merged 11 commits into from
Nov 28, 2023

Conversation

williamwoldum
Copy link
Contributor

@williamwoldum williamwoldum commented Nov 27, 2023

closes #61

  • Refactors user-endpoint and session-endpoint tests to use mock structure
  • Includes new Github Actions test workflow that uses Postgres DB
  • Made new hashing dependancy (bcrypt) injectable
    • This might seem overkill but it:
      • Allows us to mock bcrypt when testing user_logic.rs
      • Allows us to easily change encryption service in the future 🤷‍♂️
  • Made ContextCollection struct to reduce arguments (complaint by clippy)
  • Update tests modules paths
    • Resulted in a lot of indentation changes in test files which can be overlooked
    • Focus on test.yaml, tests/api/session_logic.rs, and tests/api/user_logic.rs as these are the only files with real changes

@williamwoldum williamwoldum linked an issue Nov 27, 2023 that may be closed by this pull request
Copy link
Contributor

@sabotack sabotack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

se @MadsSR's kommentar, ellers LGTM! 👍️

@williamwoldum williamwoldum merged commit d29b0c0 into main Nov 28, 2023
6 checks passed
@williamwoldum williamwoldum deleted the 58-refactor-reveaal-and-user-endpoint-tests branch November 28, 2023 11:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor reveaal and user endpoint tests
4 participants