Skip to content

Added tests for server#55

Closed
kklorfff wants to merge 2 commits into
tanjaq:mainfrom
kklorfff:main
Closed

Added tests for server#55
kklorfff wants to merge 2 commits into
tanjaq:mainfrom
kklorfff:main

Conversation

@kklorfff

Copy link
Copy Markdown

I added tests for the server using Jest and Supertest.

What was done:

Added tests for user registration
Tested different validation cases (username, password, email)
Added coverage report
Fixed tests to make them run correctly

Test command:

npx jest --coverage

Test result:

Test Suites: X passed
Tests: X passed
Time: X.XXX s

Coverage:

Statements: XX%
Branches: XX%
Functions: XX%
Lines: XX%

All tests are passing.

@github-actions

Copy link
Copy Markdown

API & Mocked Tests and Coverage

Purpose: Validate README requirements for regular tests, mocked email tests, coverage, and runtime comparison.
Status: ✅ PASS
Regular tests (app.test.js): ✅ PASS (59429ms)
Mocked tests (app.mock.test.js): ✅ PASS (1342ms)
Coverage gate (both runs at 100%): ✅ PASS
Runtime gate (regular ≥ mocked + 1500ms): ✅ PASS
Regular coverage (app.js): lines=100% | statements=100% | functions=100% | branches=100%
Mocked coverage (app.js only): lines=100% | statements=100% | functions=100% | branches=100%
Run details: https://github.com/tanjaq/User-Register/actions/runs/27421478331
PR checks: https://github.com/tanjaq/User-Register/pull/55/checks

@tanjaq

tanjaq commented Jun 13, 2026

Copy link
Copy Markdown
Owner

OK

@tanjaq tanjaq closed this Jun 13, 2026
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.

2 participants