From f0a4fd0a1a8ce79a1a0a8e570affedff3ccdec27 Mon Sep 17 00:00:00 2001 From: Denis Lugowski Date: Fri, 21 Nov 2025 10:35:38 +0100 Subject: [PATCH] fix: Load active profile testcontainers for testing --- .gitea/workflows/pipeline.yaml | 1 - .../legalconsenthub/LegalconsenthubApplicationTests.kt | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/pipeline.yaml b/.gitea/workflows/pipeline.yaml index 32e115b..ad2dd2e 100644 --- a/.gitea/workflows/pipeline.yaml +++ b/.gitea/workflows/pipeline.yaml @@ -155,7 +155,6 @@ jobs: - name: Run tests run: ./gradlew test env: - SPRING_PROFILES_ACTIVE: testcontainers # Fixes Ryuk testcontainers error during test (https://github.com/testcontainers/testcontainers-java/issues/7036) TESTCONTAINERS_HOST_OVERRIDE: host.docker.internal diff --git a/legalconsenthub-backend/src/test/kotlin/com/betriebsratkanzlei/legalconsenthub/LegalconsenthubApplicationTests.kt b/legalconsenthub-backend/src/test/kotlin/com/betriebsratkanzlei/legalconsenthub/LegalconsenthubApplicationTests.kt index 22d18cc..5e74135 100644 --- a/legalconsenthub-backend/src/test/kotlin/com/betriebsratkanzlei/legalconsenthub/LegalconsenthubApplicationTests.kt +++ b/legalconsenthub-backend/src/test/kotlin/com/betriebsratkanzlei/legalconsenthub/LegalconsenthubApplicationTests.kt @@ -2,8 +2,10 @@ package com.betriebsratkanzlei.legalconsenthub import org.junit.jupiter.api.Test import org.springframework.boot.test.context.SpringBootTest +import org.springframework.test.context.ActiveProfiles @SpringBootTest +@ActiveProfiles("testcontainers") class LegalconsenthubApplicationTests { @Test fun contextLoads() {