Skip to content

Commit 587789d

Browse files
committed
e2e test fix
Signed-off-by: Mike Lischke <mike@lischke-online.de>
1 parent 0228991 commit 587789d

1 file changed

Lines changed: 10 additions & 11 deletions

File tree

src/App.tsx

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -582,25 +582,24 @@ export class App extends UIComponent<{}, IAppState> {
582582
}
583583

584584
if (!health.configLoaded) {
585-
this.setState({ phase: AppPhase.Setup }, () => {
586-
void this.backendSetupDialogRef.current?.show({
587-
mode: "fatal",
588-
configError: health.configError,
589-
});
585+
await this.setStatePromise({ phase: AppPhase.Setup });
586+
await this.backendSetupDialogRef.current?.show({
587+
mode: "fatal",
588+
configError: health.configError,
590589
});
591590

592591
return;
593592
}
594593

595594
if (!health.initialized) {
596-
this.setState({ phase: AppPhase.Setup }, () => {
597-
void this.backendSetupDialogRef.current?.show({
598-
mode: "initial",
599-
dbError: health.dbError,
600-
});
595+
await this.setStatePromise({ phase: AppPhase.Setup });
596+
await this.backendSetupDialogRef.current?.show({
597+
mode: "initial",
598+
dbError: health.dbError,
601599
});
602600

603-
return;
601+
// Setup completed — restart the health check.
602+
return this.checkBackendThenInitialize();
604603
}
605604

606605
if (health.dbError) {

0 commit comments

Comments
 (0)