From 9b879989fe4fe2ebe90115d7ebed2a1a3552ea68 Mon Sep 17 00:00:00 2001 From: Jens L Date: Wed, 3 May 2023 17:18:03 +0300 Subject: [PATCH] tests: replace mailhog with mailpit (#5460) replace mailhog with mailpit closes #5373 Signed-off-by: Jens Langhammer --- tests/e2e/docker-compose.yml | 6 +++--- tests/e2e/test_flows_enroll.py | 8 ++++---- tests/e2e/test_flows_recovery.py | 8 ++++---- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/tests/e2e/docker-compose.yml b/tests/e2e/docker-compose.yml index c7146b83c..4787f8a71 100644 --- a/tests/e2e/docker-compose.yml +++ b/tests/e2e/docker-compose.yml @@ -2,13 +2,13 @@ version: '3.7' services: chrome: - image: selenium/standalone-chrome:110.0 + image: docker.io/selenium/standalone-chrome:110.0 volumes: - /dev/shm:/dev/shm network_mode: host restart: always - mailhog: - image: mailhog/mailhog:v1.0.1 + mailpit: + image: docker.io/axllent/mailpit:v1.6.5 ports: - 1025:1025 - 8025:8025 diff --git a/tests/e2e/test_flows_enroll.py b/tests/e2e/test_flows_enroll.py index d138c7824..5d4cc1d48 100644 --- a/tests/e2e/test_flows_enroll.py +++ b/tests/e2e/test_flows_enroll.py @@ -78,13 +78,13 @@ class TestFlowsEnroll(SeleniumTestCase): # Wait for the success message so we know the email is sent wait.until(ec.presence_of_element_located((By.CSS_SELECTOR, ".pf-c-form p"))) - # Open Mailhog + # Open Mailpit self.driver.get("http://localhost:8025") # Click on first message - self.wait.until(ec.presence_of_element_located((By.CLASS_NAME, "msglist-message"))) - self.driver.find_element(By.CLASS_NAME, "msglist-message").click() - self.driver.switch_to.frame(self.driver.find_element(By.CLASS_NAME, "tab-pane")) + self.wait.until(ec.presence_of_element_located((By.CLASS_NAME, "message"))) + self.driver.find_element(By.CLASS_NAME, "message").click() + self.driver.switch_to.frame(self.driver.find_element(By.ID, "preview-html")) self.driver.find_element(By.ID, "confirm").click() self.driver.close() self.driver.switch_to.window(self.driver.window_handles[0]) diff --git a/tests/e2e/test_flows_recovery.py b/tests/e2e/test_flows_recovery.py index 19d9b4eba..51fb64975 100644 --- a/tests/e2e/test_flows_recovery.py +++ b/tests/e2e/test_flows_recovery.py @@ -71,13 +71,13 @@ class TestFlowsRecovery(SeleniumTestCase): # Wait for the success message so we know the email is sent wait.until(ec.presence_of_element_located((By.CSS_SELECTOR, ".pf-c-form p"))) - # Open Mailhog + # Open mailpit self.driver.get("http://localhost:8025") # Click on first message - self.wait.until(ec.presence_of_element_located((By.CLASS_NAME, "msglist-message"))) - self.driver.find_element(By.CLASS_NAME, "msglist-message").click() - self.driver.switch_to.frame(self.driver.find_element(By.CLASS_NAME, "tab-pane")) + self.wait.until(ec.presence_of_element_located((By.CLASS_NAME, "message"))) + self.driver.find_element(By.CLASS_NAME, "message").click() + self.driver.switch_to.frame(self.driver.find_element(By.ID, "preview-html")) self.driver.find_element(By.ID, "confirm").click() self.driver.close() self.driver.switch_to.window(self.driver.window_handles[0])