The version-mismatch test in db_test.go opened its database only through openReportDatabase, so the default: branch of initSchema (the one that stops scan on a database stamped with a schema version other than 0 and schemaVersion) could be deleted without any test failing.
The test now also opens the same database through openScanDatabase and requires errSchemaVersion. With the default: branch removed it fails on the scan check.
It is renamed from TestOpenReportDatabaseVersionMismatch to TestOpenDatabaseVersionMismatch, matching TestOpenDatabaseUnversionedForeign beside it, which already checks both the report and the scan path for the unversioned case added in #58.
No production code changes.
Model: opus-5-5
The version-mismatch test in `db_test.go` opened its database only through `openReportDatabase`, so the `default:` branch of `initSchema` (the one that stops `scan` on a database stamped with a schema version other than 0 and `schemaVersion`) could be deleted without any test failing.
The test now also opens the same database through `openScanDatabase` and requires `errSchemaVersion`. With the `default:` branch removed it fails on the `scan` check.
It is renamed from `TestOpenReportDatabaseVersionMismatch` to `TestOpenDatabaseVersionMismatch`, matching `TestOpenDatabaseUnversionedForeign` beside it, which already checks both the report and the scan path for the unversioned case added in https://git.eeqj.de/sneak/sfdupes/pulls/58.
No production code changes.
Model: opus-5-5
The version-mismatch test only opened its database through
openReportDatabase, so nothing exercised the branch of initSchema that
stops scan on a database stamped with an unknown schema version. The
test now opens the same database through openScanDatabase too and
requires errSchemaVersion, and is renamed to match the unversioned-file
test beside it, which also covers both paths.
Model: opus-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
The version-mismatch test in
db_test.goopened its database only throughopenReportDatabase, so thedefault:branch ofinitSchema(the one that stopsscanon a database stamped with a schema version other than 0 andschemaVersion) could be deleted without any test failing.The test now also opens the same database through
openScanDatabaseand requireserrSchemaVersion. With thedefault:branch removed it fails on thescancheck.It is renamed from
TestOpenReportDatabaseVersionMismatchtoTestOpenDatabaseVersionMismatch, matchingTestOpenDatabaseUnversionedForeignbeside it, which already checks both the report and the scan path for the unversioned case added in #58.No production code changes.
Model: opus-5-5
Review passed.
Model: opus-5-5
9776984e19tod68ba10071Rebased onto
next; only theTODO.mdentry conflicted.Model: opus-5-5