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

reworked middleware to add token route and validate users #25

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

Linesmerrill
Copy link
Owner

@Linesmerrill Linesmerrill commented May 30, 2024

🛑 DO NOT MERGE until testing has been completed in the front end 🛑

  • reworked middleware to add token route and validate users

⚠️ Includes Breaking Changes around the Auth Token for middleware routes. This will require that the frontend sends the token from /api/v1/auth/token along each request as the bearer token. Without this, it will fail.
⚠️ Updates go version to v1.22

  • Front end has been tested

Copy link

codecov bot commented Jun 24, 2024

Codecov Report

Attention: Patch coverage is 4.32612% with 575 lines in your changes missing coverage. Please review.

Project coverage is 57.44%. Comparing base (93de263) to head (f6210a1).

Current head f6210a1 differs from pull request most recent head 292de2d

Please upload reports for the commit 292de2d to get more accurate results.

Files Patch % Lines
databases/mocks/SpotlightDatabase.go 0.00% 77 Missing ⚠️
api/handlers/user.go 0.00% 70 Missing ⚠️
api/handlers/spotlight.go 0.00% 62 Missing ⚠️
api/middleware.go 19.29% 46 Missing ⚠️
databases/mocks/UserDatabase.go 0.00% 31 Missing ⚠️
databases/mocks/CollectionHelper.go 0.00% 28 Missing and 2 partials ⚠️
databases/spotlight.go 0.00% 25 Missing ⚠️
databases/mocks/InsertOneResultHelper.go 0.00% 19 Missing ⚠️
databases/mocks/CallDatabase.go 0.00% 18 Missing ⚠️
databases/mocks/CivilianDatabase.go 0.00% 18 Missing ⚠️
... and 13 more
Additional details and impacted files
@@             Coverage Diff             @@
##             main      #25       +/-   ##
===========================================
- Coverage   99.64%   57.44%   -42.20%     
===========================================
  Files          23       44       +21     
  Lines        1411     2578     +1167     
===========================================
+ Hits         1406     1481       +75     
- Misses          4     1083     +1079     
- Partials        1       14       +13     
Flag Coverage Δ
unittests 57.44% <4.32%> (-42.20%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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.

None yet

1 participant