-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
Description
The Timetable.load method in supertask/model.py has branches for JSON and YAML loading as well as error handling for unsupported file types, but these aren't covered by tests.
Requirements
Please add tests for:
- Loading a JSON file via
Timetable.load(…)and verifying the returned data - Loading a
.ymlfile (if treated differently than.yaml) - Passing an unsupported extension (e.g.
.txt) and asserting thatNotImplementedErroris raised
Reference
- PR: Refactor data model and CLI. Remove HTTP service. #155
- Comment: Refactor data model and CLI. Remove HTTP service. #155 (comment)
Technical Details
The method is located at lines 181-189 in supertask/model.py. Current tests only exercise the YAML branch.
Suggested locations to add tests:
tests/test_core.pyor a new file undertests/- Consider using temporary files or fixtures for JSON/.yml content and an invalid-extension case.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels