test(autosave): wait for the retried snapshot metadata

Recovery discovery can list a committed bundle before its sidecar is published. Wait for the expected revision rather than treating a fallback entry as write completion. Keep all failure, retry, revision and pixel assertions.

Co-authored-by: GPT-6 <noreply@openai.com>
This commit is contained in:
augrclkandGPT-6 committed 2026-10-14 14:12:44 +03:00
1 parent 8cc08cdd52
commit ff0eb52d7a
1 file changed
+3 -1
+3 -1
View File
@@ -932,7 +932,9 @@ mod tests {
while std::time::Instant::now() < deadline {
prefs_ui::tick(&mut app, &ctx);
recovered = list_recovery(&recovery);
if !recovered.is_empty() {
// A committed bundle is recoverable before its sidecar is published. Wait for
// the sidecar's revision, not the early fallback entry (revision 0).
if recovered.len() == 1 && recovered[0].info.revision == revision {
break;
}
std::thread::sleep(std::time::Duration::from_millis(10));