Closed PGijsbers closed 5 days ago
This pull request focuses on improving the test suite by adding documentation on using fixtures and mocks, replacing some integration-style tests with lighter versions, and adding verified user constants. The changes aim to enhance test performance and provide guidance for writing more efficient tests.
classDiagram
class User {
int user_id
Connection _database
List~UserGroup~ _groups
}
class UserGroup {
<<enumeration>>
ADMIN
READ_WRITE
}
User --> UserGroup : has
note for User "Represents a user with associated groups and database connection"
classDiagram
class ApiKey {
<<enumeration>>
ADMIN
REGULAR_USER
OWNER_USER
INVALID
}
note for ApiKey "Represents different types of API keys as string enumerations"
Change | Details | Files |
---|---|---|
Added documentation on using fixtures and mocks in tests |
|
docs/contributing/tests.md mkdocs.yml |
Replaced integration-style tests with lighter versions |
|
tests/routers/openml/datasets_test.py |
Added verified user constants and refactored user-related code |
|
tests/routers/openml/users_test.py tests/conftest.py tests/routers/openml/datasets_list_datasets_test.py |
All modified and coverable lines are covered by tests :white_check_mark:
Please upload report for BASE (
main@dd9682c
). Learn more about missing BASE report.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Summary by Sourcery
Refactor tests to improve performance by replacing some integration tests with lighter versions and introduce verified user constants. Add documentation on using fixtures and mocks in tests to guide developers in writing efficient tests.
New Features:
Enhancements:
Documentation:
Tests: