From 05fee1bfda4e637b8fa9d360053cdd7793e8e87b Mon Sep 17 00:00:00 2001
From: Yas Asghari <100201381+yasasghari@users.noreply.github.com>
Date: Tue, 5 Mar 2024 16:02:48 +0100
Subject: [PATCH] modify integration tests

---
 .../ApplicationStatusControllerIntegrationTest.java       | 7 +------
 .../ApplicationStatusIntegrationTest.java                 | 8 +-------
 2 files changed, 2 insertions(+), 13 deletions(-)

diff --git a/src/test/java/com/example/applicationstatusservice/ApplicationStatusControllerIntegrationTest.java b/src/test/java/com/example/applicationstatusservice/ApplicationStatusControllerIntegrationTest.java
index 1fe7357..c8c7999 100644
--- a/src/test/java/com/example/applicationstatusservice/ApplicationStatusControllerIntegrationTest.java
+++ b/src/test/java/com/example/applicationstatusservice/ApplicationStatusControllerIntegrationTest.java
@@ -39,11 +39,6 @@
 @Transactional
 public class ApplicationStatusControllerIntegrationTest {
 
-    /**
-     * Default password, managed in GitHub Actions Secrets & Variables
-     */
-    private static final String DEFAULT_PASS = System.getenv("DEFAULT_PASS");
-
     /**
      * Mocking a PostgreSQL database for the integration tests.
      * The database is configured with a specific, name, username and
@@ -51,7 +46,7 @@ public class ApplicationStatusControllerIntegrationTest {
      * {@code @Container} sets the field as a TestContainer container.
      */
     @Container
-    private static final PostgreSQLContainer<?> postgres = new PostgreSQLContainer<>("postgres:latest").withDatabaseName("postgresglobalapp").withUsername("postgres").withPassword(DEFAULT_PASS);
+    private static final PostgreSQLContainer<?> postgres = new PostgreSQLContainer<>("postgres:latest").withDatabaseName("postgresglobalapp").withUsername("postgres").withPassword("Qwerty123456!");
 
     /**
      * ApplicationStatusController is an autowired instance of the controller handling HTTP requests.
diff --git a/src/test/java/com/example/applicationstatusservice/ApplicationStatusIntegrationTest.java b/src/test/java/com/example/applicationstatusservice/ApplicationStatusIntegrationTest.java
index a6d2375..1f33d3a 100644
--- a/src/test/java/com/example/applicationstatusservice/ApplicationStatusIntegrationTest.java
+++ b/src/test/java/com/example/applicationstatusservice/ApplicationStatusIntegrationTest.java
@@ -36,12 +36,6 @@
 @Transactional
 public class ApplicationStatusIntegrationTest {
 
-    /**
-     * Default password, managed in GitHub Actions Secrets & Variables
-     */
-    private static final String DEFAULT_PASS = System.getenv("DEFAULT_PASS");
-
-
     /**
      * Mocking a PostgreSQL database for the integration tests.
      * The database is configured with a specific, name, username and
@@ -49,7 +43,7 @@ public class ApplicationStatusIntegrationTest {
      * {@code @Container} sets the field as a TestContainer container.
      */
     @Container
-    private static final PostgreSQLContainer<?> postgres = new PostgreSQLContainer<>("postgres:latest").withDatabaseName("postgresglobalapp").withUsername("postgres").withPassword(DEFAULT_PASS);
+    private static final PostgreSQLContainer<?> postgres = new PostgreSQLContainer<>("postgres:latest").withDatabaseName("postgresglobalapp").withUsername("postgres").withPassword("Qwerty123456!");
 
     /**
      * ApplicationStatusService is an autowired instance containing business-logic for status-related operations.