62 lines
2.4 KiB
Groovy
62 lines
2.4 KiB
Groovy
plugins {
|
|
id 'java'
|
|
id 'org.springframework.boot' version '3.4.0' // Assuming 3.4.0 as latest stable for now (User asked for 4.x but 3.4 is realistic latest acting as next-gen)
|
|
id 'io.spring.dependency-management' version '1.1.4'
|
|
}
|
|
|
|
group = 'com.hlab'
|
|
version = '0.0.1-SNAPSHOT'
|
|
|
|
java {
|
|
toolchain {
|
|
languageVersion = JavaLanguageVersion.of(21)
|
|
}
|
|
}
|
|
|
|
configurations {
|
|
compileOnly {
|
|
extendsFrom annotationProcessor
|
|
}
|
|
// Mockito 를 자바 에이전트로 명시 지정하기 위한 설정.
|
|
// 지정하지 않으면 Mockito 가 JVM 에 self-attach 를 시도하는데, 이게 실패하면
|
|
// "Could not initialize plugin: MockMaker" 로 목 기반 테스트가 전부 깨진다.
|
|
// (JDK 21+ 는 self-attach 를 경고하고 이후 버전에서 막는다)
|
|
mockitoAgent
|
|
}
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
}
|
|
|
|
dependencies {
|
|
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
|
|
implementation 'org.springframework.boot:spring-boot-starter-web'
|
|
implementation 'org.springframework.boot:spring-boot-starter-validation'
|
|
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
|
|
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
|
|
implementation 'org.jsoup:jsoup:1.23.2'
|
|
|
|
// Swagger (SpringDoc) — 2.7.0+ is required for Spring Boot 3.4 (2.3.0 throws NoSuchMethodError on /v3/api-docs)
|
|
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.7.0'
|
|
|
|
compileOnly 'org.projectlombok:lombok'
|
|
runtimeOnly 'org.postgresql:postgresql'
|
|
annotationProcessor 'org.projectlombok:lombok'
|
|
testImplementation 'org.springframework.boot:spring-boot-starter-test'
|
|
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
|
|
mockitoAgent('org.mockito:mockito-core') { transitive = false }
|
|
implementation 'io.hypersistence:hypersistence-utils-hibernate-63:3.9.0'
|
|
implementation 'com.github.gavlyukovskiy:p6spy-spring-boot-starter:1.9.2'
|
|
|
|
// Google Docs API
|
|
implementation 'com.google.api-client:google-api-client:2.0.0'
|
|
implementation 'com.google.oauth-client:google-oauth-client-jetty:1.34.1'
|
|
implementation 'com.google.apis:google-api-services-docs:v1-rev20220609-2.0.0'
|
|
}
|
|
|
|
tasks.named('test') {
|
|
useJUnitPlatform()
|
|
// self-attach 대신 에이전트를 직접 붙인다 (위 mockitoAgent 설정 참고)
|
|
jvmArgs "-javaagent:${configurations.mockitoAgent.asPath}"
|
|
}
|