diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 3211e149..6ad4a1b3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -169,7 +169,8 @@ e2e: artifacts: expire_in: 2 days paths: - - js/playwright-report + - js/playwright-report/ + - js/test-results/ pages: stage: deploy diff --git a/js/src/views/User/LoginView.vue b/js/src/views/User/LoginView.vue index 78a89be3..53796faf 100644 --- a/js/src/views/User/LoginView.vue +++ b/js/src/views/User/LoginView.vue @@ -100,12 +100,7 @@ }" >{{ t("Didn't receive the instructions?") }} -

+

configResult.value?.config); +const canRegister = computed(() => { + return ( + (config.value?.registrationsOpen || config.value?.registrationsAllowlist) && + config.value?.auth.databaseLogin + ); +}); + const errors = ref([]); const submitted = ref(false); diff --git a/js/tests/e2e/login.spec.ts b/js/tests/e2e/login.spec.ts index f7f11dc6..85ecc31e 100644 --- a/js/tests/e2e/login.spec.ts +++ b/js/tests/e2e/login.spec.ts @@ -14,7 +14,9 @@ test("Login has everything we need", async ({ page }) => { hasText: "Didn't receive the instructions?", }); - const registerLink = page.locator("a", { hasText: "Create an account" }); + const registerLink = page.locator("a > span > span", { + hasText: "Create an account", + }); await expect(forgotPasswordLink).toBeVisible(); await expect(reAskInstructionsLink).toBeVisible();