From 6cc2c1d78ebce0bf9160966c64b5b2c01e214c64 Mon Sep 17 00:00:00 2001 From: Donghun Won Date: Wed, 18 Sep 2024 15:30:41 +0900 Subject: [PATCH] =?UTF-8?q?Fix=20:=20test=20schema=20=ED=8C=8C=EC=9D=BC=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/deploy.yml | 6 +++--- .../solitour_backend/solitour/SolitourApplicationTests.java | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index f209a87..5893794 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -28,9 +28,9 @@ jobs: echo "${{ secrets.APPLICATION_LOCAL }}" > ./src/main/resources/application-local.yml echo "${{ secrets.APPLICATION_TEST }}" > ./src/main/resources/application-test.yml -# - name: sql 파일 만들기 -# run: | -# echo "${{ secrets.SCHEMA }}" > ./src/main/resources/schema.sql + - name: sql 파일 만들기 + run: | + echo "${{ secrets.TEST_SCHEMA }}" > ./src/main/resources/test_schema.sql # echo "${{ secrets.CATEGORY }}" > ./src/main/resources/category.sql # echo "${{ secrets.GATHERING_CATEGORY }}" > ./src/main/resources/gathering_category.sql # echo "${{ secrets.ZONE_CATEGORY }}" > ./src/main/resources/zone_category.sql diff --git a/src/test/java/solitour_backend/solitour/SolitourApplicationTests.java b/src/test/java/solitour_backend/solitour/SolitourApplicationTests.java index aac74b1..b8fbd10 100644 --- a/src/test/java/solitour_backend/solitour/SolitourApplicationTests.java +++ b/src/test/java/solitour_backend/solitour/SolitourApplicationTests.java @@ -1,10 +1,12 @@ package solitour_backend.solitour; import org.junit.jupiter.api.Test; +import org.springframework.boot.test.autoconfigure.jdbc.AutoConfigureTestDatabase; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.ActiveProfiles; @SpringBootTest +@AutoConfigureTestDatabase(replace = AutoConfigureTestDatabase.Replace.ANY) @ActiveProfiles("test") class SolitourApplicationTests {