Skip to content

Privacy-first password manager with built-in email aliasing. Fully encrypted and self-hostable.

Update ClientPlaywrightTest.cs

Leendert de Borst5cb22c40d775
diff --git a/apps/server/Tests/AliasVault.E2ETests/Common/ClientPlaywrightTest.cs b/apps/server/Tests/AliasVault.E2ETests/Common/ClientPlaywrightTest.cs
index 49ef62647..792e4ee5c 100644
--- a/apps/server/Tests/AliasVault.E2ETests/Common/ClientPlaywrightTest.cs
+++ b/apps/server/Tests/AliasVault.E2ETests/Common/ClientPlaywrightTest.cs
@@ -501,6 +501,12 @@ public abstract class ClientPlaywrightTest : PlaywrightTest
/// <returns>Async task.</returns>
protected async Task Register(bool checkForSuccess = true, string? username = null, string? password = null)
{
+ // Check that we are on the login page after navigating to the base URL.
+ // This hard navigation ensures the Blazor app is fully reset, which is important
+ // after logout to ensure the router is in a clean state.
+ await Page.GotoAsync(AppBaseUrl);
+ await WaitForUrlAsync("user/start", "Log in with");
+
// Try to register a new account.
await NavigateUsingBlazorRouter("user/register");
await WaitForUrlAsync("user/register", "Create account");