EtienneDx / git-mentor

A git server with built-in tools for teaching programming
MIT License
2 stars 0 forks source link

Added authentication verification to the APIs #38

Closed EtienneDx closed 2 months ago

EtienneDx commented 2 months ago

Using the GmtToken class, it is now possible to verify a user is connected and retrieve its infos in a simple manner.

This PR comes with an example usage in the HelloService class.

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 80.76923% with 5 lines in your changes are missing coverage. Please review.

Project coverage is 85.22%. Comparing base (e41ca33) to head (b0f9062).

Files Patch % Lines
gmt-api/src/services/hello_service.rs 42.85% 4 Missing :warning:
gmt-api/src/security/gmt_token.rs 88.88% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #38 +/- ## ======================================= Coverage 85.22% 85.22% ======================================= Files 34 35 +1 Lines 2382 2403 +21 ======================================= + Hits 2030 2048 +18 - Misses 352 355 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

EtienneDx commented 2 months ago

Note: coverage report is mistaken, I'm guessing it doesn't like the force push