Repository navigation
Expand file tree
/
Copy pathbuild.gradle
More file actions
73 lines (67 loc) · 3.46 KB
/
Copy pathbuild.gradle
File metadata and controls
73 lines (67 loc) · 3.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
plugins {
id 'java'
id 'org.springframework.boot' version '4.1.2'
id 'io.spring.dependency-management' version '1.1.7'
}
group = 'com.sniptext'
version = '0.0.1-SNAPSHOT'
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}
repositories {
mavenCentral()
}
ext {
springdocVersion = '3.1.1'
querydslVersion = '7.7'
archunitVersion = '1.5.1'
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-actuator'
implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
implementation 'org.springframework.boot:spring-boot-starter-flyway'
implementation 'org.springframework.boot:spring-boot-starter-security'
implementation 'org.springframework.boot:spring-boot-starter-validation'
implementation 'org.springframework.boot:spring-boot-starter-webmvc'
// 접근 토큰 서명·검증과 구글 ID 토큰 검증을 같은 라이브러리로 처리한다 (리소스 서버 스타터는 쓰지 않는다)
implementation 'org.springframework.security:spring-security-oauth2-jose'
implementation 'org.flywaydb:flyway-mysql'
implementation "org.springdoc:springdoc-openapi-starter-webmvc-ui:${springdocVersion}"
implementation "io.github.openfeign.querydsl:querydsl-jpa:${querydslVersion}"
compileOnly 'org.projectlombok:lombok'
developmentOnly 'org.springframework.boot:spring-boot-docker-compose'
runtimeOnly 'com.mysql:mysql-connector-j'
annotationProcessor 'org.projectlombok:lombok'
annotationProcessor "io.github.openfeign.querydsl:querydsl-apt:${querydslVersion}:jpa"
annotationProcessor 'jakarta.persistence:jakarta.persistence-api'
annotationProcessor 'jakarta.annotation:jakarta.annotation-api'
testImplementation 'org.springframework.boot:spring-boot-starter-actuator-test'
testImplementation 'org.springframework.boot:spring-boot-starter-data-jpa-test'
testImplementation 'org.springframework.boot:spring-boot-starter-flyway-test'
testImplementation 'org.springframework.boot:spring-boot-starter-security-test'
testImplementation 'org.springframework.boot:spring-boot-starter-validation-test'
testImplementation 'org.springframework.boot:spring-boot-starter-webmvc-test'
testImplementation 'org.springframework.boot:spring-boot-testcontainers'
testImplementation 'org.testcontainers:testcontainers-junit-jupiter'
testImplementation 'org.testcontainers:testcontainers-mysql'
testImplementation "com.tngtech.archunit:archunit-junit5:${archunitVersion}"
testCompileOnly 'org.projectlombok:lombok'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher'
testAnnotationProcessor 'org.projectlombok:lombok'
}
tasks.named('test') {
useJUnitPlatform()
systemProperty 'user.timezone', 'Asia/Seoul'
// 테스트 전용 서명 키. src/test/resources/application.yml은 운영 설정을 통째로 가리므로 만들지 않는다
environment 'JWT_SECRET', 'test-only-jwt-secret-do-not-use-anywhere-else'
// 테스트 전용 본문 암호화 키 (Base64로 인코딩한 32바이트)
environment 'CONTENT_ENCRYPTION_KEY', 'RipPBY6rYeoR+15yb9ooY0ghmKpl6XwA8XMoAslj0oA='
// 테스트는 외부를 부르지 않는 가짜 언어 모델을 쓴다 (prod 프로필 테스트는 클래스에서 anthropic으로 덮어쓴다)
environment 'AI_PROVIDER', 'fake'
// 테스트 전용 구글 설정 (테스트는 구글에 접속하지 않는다)
environment 'GOOGLE_CLIENT_ID', 'test-google-client-id'
environment 'GOOGLE_CLIENT_SECRET', 'test-google-client-secret'
environment 'GOOGLE_REDIRECT_URIS', 'http://localhost:5173/auth/google/callback'
}