Skip to content

Commit

Permalink
fix: 테스트 시 Too many connections 오류 해결
Browse files Browse the repository at this point in the history
  • Loading branch information
DrumRobot committed Apr 2, 2024
1 parent 579a8ea commit 2af45d4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,5 @@ jobs:

- name: Run Gradle Test
run: ./gradlew test
env:
SPRING_PROFILES_ACTIVE: dev
4 changes: 4 additions & 0 deletions src/main/resources/application-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ spring:
username: ${DB_USER}
password: ${DB_PASS}
driver-class-name: org.mariadb.jdbc.Driver
hikari:
initializationFailTimeout: 9000
maximum-pool-size: 3
minimum-idle: 1
2 changes: 1 addition & 1 deletion src/test/java/picdiary/diary/service/DiaryServiceTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public class DiaryServiceTest {

@Test
public void testDiary() {
DiaryCreateRequest createRequest = DiaryCreateRequest.builder().date(date).emotion(emotion).build();
DiaryCreateRequest createRequest = DiaryCreateRequest.builder().content("test").date(date).emotion(emotion).build();
diaryId = diaryService.createDiary(userId, createRequest);
assertNotNull(diaryId);

Expand Down

0 comments on commit 2af45d4

Please sign in to comment.