Skip to content

Commit

Permalink
chore: fix test failure
Browse files Browse the repository at this point in the history
  • Loading branch information
Jiin Kim authored and Jiin Kim committed Dec 27, 2024
1 parent 1574f4a commit 98bd45e
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 8 deletions.
1 change: 1 addition & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ tasks.named<BootJar>("bootJar") {

tasks.withType<Test> {
useJUnitPlatform()
systemProperty("spring.profiles.active", "test")
}

tasks.named<BootBuildImage>("bootBuildImage") {
Expand Down
2 changes: 1 addition & 1 deletion src/main/kotlin/com/kogo/content/DataBootstrap.kt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import org.springframework.web.client.RestTemplate
import java.time.Instant

@Service
@Profile("!test")
@Profile("local || stg || prd")
class DataBootstrap(private val mongoTemplate: MongoTemplate) {

@Value("\${kogo-api.getSchools}")
Expand Down
4 changes: 2 additions & 2 deletions src/main/kotlin/com/kogo/content/search/AtlasSearchConfig.kt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import org.springframework.context.annotation.Profile
import org.springframework.data.mongodb.core.MongoTemplate

@Configuration
@Profile("!local")
@Profile("stg || prd")
class AtlasSearchConfig @Autowired constructor(
private val applicationContext: ApplicationContext,
private val mongoTemplate: MongoTemplate
Expand Down Expand Up @@ -164,4 +164,4 @@ class AtlasSearchConfig @Autowired constructor(
throw e
}
}
}
}
5 changes: 0 additions & 5 deletions src/test/resources/application-test.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
---
compileVersionKey: "1.0.0"

server:
port: 8081

Expand All @@ -12,6 +10,3 @@ spring:
username: testuser
password: testpass
auto-index-creation: true

filehandler:
prefix: tmp/files

0 comments on commit 98bd45e

Please sign in to comment.