Expect a damaged-database message when recovering an overwritten page

Since the integrity check on opening a .qetz database (#1499) runs before
anything is read, an overwritten page is reported as "the project
database is damaged", not "cannot be read". recoverLeavesOutOnlyTheDamage
was written before that check and has failed on master since #1504.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MgPFANhWgD66V3v9KVKV58
This commit is contained in:
ispyisail
2026-10-16 17:14:12 +13:00
parent 6b08b87d16
commit 0f65e912e7
+1 -1
View File
@@ -809,7 +809,7 @@ private slots:
QTest::newRow("nothing") << QString() << QString() << 0 << 0;
QTest::newRow("folio file missing") << QStringLiteral("folio") << QStringLiteral("is missing") << -1 << 0;
QTest::newRow("wire row deleted") << QStringLiteral("row") << QStringLiteral("not in the database") << 0 << -1;
QTest::newRow("database page overwritten") << QStringLiteral("page") << QStringLiteral("cannot be read") << 0 << -1000;
QTest::newRow("database page overwritten") << QStringLiteral("page") << QStringLiteral("is damaged") << 0 << -1000;
}
void recoverLeavesOutOnlyTheDamage()
{