test: CSV and ODS import/export handler test coverage #77
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Ref:
docs/ROADMAP.md§ Appendix B / 1.4 Unit Test SuiteNo handler-level tests for CSV or ODS endpoints. The ODS package has unit tests (
internal/ods/ods_test.go, 10 tests) but the API handlers that use it are untested.CSV handlers (
internal/api/csv.go, ~593 lines):HandleExportCSV— column selection, filtering, output formatHandleImportCSV— dry-run validation, upsert, error reportingHandleCSVTemplate— template generation per schemaODS handlers (
internal/api/ods.go, ~1061 lines):HandleExportODS— item export with propertiesHandleImportODS— item import with validationHandleODSTemplate— template generationHandleExportBOMODS— BOM export to ODSHandleProjectSheetODS— project sheet exportFocus on round-trip correctness: export then re-import should produce equivalent data.