From 122f54dd4f9ad682e52b89aca50e7cc43d53ef15 Mon Sep 17 00:00:00 2001 From: orakili Date: Mon, 2 Dec 2024 16:30:29 +0000 Subject: [PATCH] refactor: change route of reliefweb_entraid to avoid conflict with ocha_entraid module Refs: OPS-10828 --- html/modules/custom/reliefweb_entraid/README.md | 2 +- .../custom/reliefweb_entraid/reliefweb_entraid.routing.yml | 2 +- .../tests/src/ExistingSite/ReliefwebEntraidLoginTest.php | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/html/modules/custom/reliefweb_entraid/README.md b/html/modules/custom/reliefweb_entraid/README.md index 80749267f..606980f96 100644 --- a/html/modules/custom/reliefweb_entraid/README.md +++ b/html/modules/custom/reliefweb_entraid/README.md @@ -3,4 +3,4 @@ Reliefweb Entra ID This module provides user authentication tweaks for Entra ID -* Provide a `/user/login/entraid` callback to redirect to the Entra ID login workflow. +* Provide a `/user/login/reliefweb-entraid-direct` callback to redirect to the Entra ID login workflow. diff --git a/html/modules/custom/reliefweb_entraid/reliefweb_entraid.routing.yml b/html/modules/custom/reliefweb_entraid/reliefweb_entraid.routing.yml index 93872e877..3d624198d 100644 --- a/html/modules/custom/reliefweb_entraid/reliefweb_entraid.routing.yml +++ b/html/modules/custom/reliefweb_entraid/reliefweb_entraid.routing.yml @@ -1,5 +1,5 @@ reliefweb_entraid.login: - path: '/user/login/entraid' + path: '/user/login/reliefweb-entraid-direct' defaults: _controller: '\Drupal\reliefweb_entraid\Controller\AuthController::redirectLogin' _title: 'Login with Unite ID' diff --git a/html/modules/custom/reliefweb_entraid/tests/src/ExistingSite/ReliefwebEntraidLoginTest.php b/html/modules/custom/reliefweb_entraid/tests/src/ExistingSite/ReliefwebEntraidLoginTest.php index 4ba5e1e9c..a925ff088 100644 --- a/html/modules/custom/reliefweb_entraid/tests/src/ExistingSite/ReliefwebEntraidLoginTest.php +++ b/html/modules/custom/reliefweb_entraid/tests/src/ExistingSite/ReliefwebEntraidLoginTest.php @@ -63,7 +63,7 @@ public function testRedirectLogin() { // The incomplete config will results in an exception and 404 response // will be returned. - $this->drupalGet('/user/login/entraid'); + $this->drupalGet('/user/login/reliefweb-entraid-direct'); $this->assertSession()->statusCodeEquals(404); // Set the endpoints. We just point at the robots.txt as we know it exists @@ -75,7 +75,7 @@ public function testRedirectLogin() { $entraid_config->setData($data)->save(); // If the redirection works, a 200 will be returned. - $this->drupalGet('/user/login/entraid'); + $this->drupalGet('/user/login/reliefweb-entraid-direct'); $this->assertSession()->statusCodeEquals(200); $this->assertStringContainsString('Disallow:', $this->getSession()->getPage()->getContent()); }