Clean gradle build
This commit is contained in:
parent
90701dcdce
commit
909fb482a8
@ -1,33 +1,36 @@
|
||||
import be.simplenotes.Libs
|
||||
import be.simplenotes.micronaut
|
||||
|
||||
plugins {
|
||||
id("be.simplenotes.base")
|
||||
id("be.simplenotes.kotlinx-serialization")
|
||||
id("be.simplenotes.app-shadow")
|
||||
id("be.simplenotes.app-css")
|
||||
id("be.simplenotes.app-docker")
|
||||
kotlin("kapt")
|
||||
id("be.simplenotes.docker")
|
||||
id("be.simplenotes.micronaut")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(project(":domain"))
|
||||
implementation(project(":types"))
|
||||
implementation(project(":config"))
|
||||
implementation(project(":views"))
|
||||
implementation(project(":css"))
|
||||
|
||||
implementation(Libs.arrowCoreData)
|
||||
implementation(Libs.konform)
|
||||
implementation(Libs.http4kCore)
|
||||
implementation(Libs.jettyServer)
|
||||
implementation(Libs.jettyServlet)
|
||||
implementation(Libs.Http4k.core)
|
||||
implementation(Libs.Jetty.server)
|
||||
implementation(Libs.Jetty.servlet)
|
||||
implementation(Libs.javaxServlet)
|
||||
implementation(Libs.kotlinxSerializationJson)
|
||||
implementation(Libs.logbackClassic)
|
||||
implementation(Libs.Kotlinx.Serialization.json)
|
||||
|
||||
implementation(Libs.micronaut)
|
||||
kapt(Libs.micronautProcessor)
|
||||
implementation(Libs.Slf4J.api)
|
||||
runtimeOnly(Libs.Slf4J.logback)
|
||||
|
||||
testImplementation(Libs.junit)
|
||||
testImplementation(Libs.assertJ)
|
||||
testImplementation(Libs.http4kTestingHamkrest)
|
||||
micronaut()
|
||||
|
||||
testImplementation(Libs.Test.junit)
|
||||
testImplementation(Libs.Test.assertJ)
|
||||
testImplementation(Libs.Http4k.testingHamkrest)
|
||||
}
|
||||
|
||||
docker {
|
||||
image = "hubv/simplenotes"
|
||||
tag = "latest"
|
||||
}
|
||||
|
||||
3
build.gradle.kts
Normal file
3
build.gradle.kts
Normal file
@ -0,0 +1,3 @@
|
||||
plugins {
|
||||
id("be.simplenotes.versions")
|
||||
}
|
||||
@ -1,2 +1,3 @@
|
||||
org.gradle.jvmargs=-Xmx2048M -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
|
||||
org.gradle.caching=true
|
||||
org.gradle.parallel=true
|
||||
|
||||
44
buildSrc/src/main/kotlin/be/simplenotes/DockerPlugin.kt
Normal file
44
buildSrc/src/main/kotlin/be/simplenotes/DockerPlugin.kt
Normal file
@ -0,0 +1,44 @@
|
||||
package be.simplenotes
|
||||
|
||||
import org.gradle.api.Plugin
|
||||
import org.gradle.api.Project
|
||||
import org.gradle.kotlin.dsl.create
|
||||
|
||||
open class DockerPluginExtension {
|
||||
var image: String? = null
|
||||
var tag = "latest"
|
||||
}
|
||||
|
||||
class DockerPlugin : Plugin<Project> {
|
||||
override fun apply(project: Project) {
|
||||
val extension = project.extensions.create<DockerPluginExtension>("docker")
|
||||
|
||||
project.task("dockerBuild") {
|
||||
dependsOn("package")
|
||||
|
||||
group = "docker"
|
||||
description = "Build a docker image"
|
||||
|
||||
doLast {
|
||||
project.exec {
|
||||
commandLine("docker", "build", "-t", "${extension.image}:${extension.tag}", ".")
|
||||
workingDir(project.rootProject.projectDir)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
project.task("dockerPush") {
|
||||
dependsOn("dockerBuild")
|
||||
|
||||
group = "docker"
|
||||
description = "Push a docker image"
|
||||
|
||||
doLast {
|
||||
project.exec {
|
||||
commandLine("docker", "push", "${extension.image}:${extension.tag}")
|
||||
workingDir(project.rootProject.projectDir)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -3,43 +3,90 @@
|
||||
package be.simplenotes
|
||||
|
||||
object Libs {
|
||||
|
||||
object Flexmark {
|
||||
private const val version = "0.62.2"
|
||||
const val core = "com.vladsch.flexmark:flexmark:$version"
|
||||
const val tasklist = "com.vladsch.flexmark:flexmark-ext-gfm-tasklist:$version"
|
||||
}
|
||||
|
||||
object Database {
|
||||
const val flyway = "org.flywaydb:flyway-core:6.5.4"
|
||||
const val hikariCP = "com.zaxxer:HikariCP:3.4.3"
|
||||
|
||||
object Drivers {
|
||||
const val h2 = "com.h2database:h2:1.4.200"
|
||||
const val mariadb = "org.mariadb.jdbc:mariadb-java-client:2.6.2"
|
||||
}
|
||||
|
||||
object Ktorm {
|
||||
private const val version = "3.0.0"
|
||||
const val core = "me.liuwj.ktorm:ktorm-core:$version"
|
||||
const val mysql = "me.liuwj.ktorm:ktorm-support-mysql:$version"
|
||||
}
|
||||
}
|
||||
|
||||
object Lucene {
|
||||
private const val version = "8.6.1"
|
||||
const val core = "org.apache.lucene:lucene-core:$version"
|
||||
const val analyzersCommon = "org.apache.lucene:lucene-analyzers-common:$version"
|
||||
const val queryParser = "org.apache.lucene:lucene-queryparser:$version"
|
||||
}
|
||||
|
||||
object Http4k {
|
||||
private const val version = "3.268.0"
|
||||
const val core = "org.http4k:http4k-core:$version"
|
||||
const val testingHamkrest = "org.http4k:http4k-testing-hamkrest:$version"
|
||||
}
|
||||
|
||||
object Jetty {
|
||||
private const val version = "9.4.32.v20200930"
|
||||
const val server = "org.eclipse.jetty:jetty-server:$version"
|
||||
const val servlet = "org.eclipse.jetty:jetty-servlet:$version"
|
||||
}
|
||||
|
||||
object Kotlinx {
|
||||
const val html = "org.jetbrains.kotlinx:kotlinx-html-jvm:0.7.1"
|
||||
|
||||
object Serialization {
|
||||
const val json = "org.jetbrains.kotlinx:kotlinx-serialization-json-jvm:1.0.0"
|
||||
}
|
||||
}
|
||||
|
||||
object Slf4J {
|
||||
const val api = "org.slf4j:slf4j-api:1.7.25"
|
||||
const val logback = "ch.qos.logback:logback-classic:1.2.3"
|
||||
}
|
||||
|
||||
object Mapstruct {
|
||||
private const val version = "1.4.1.Final"
|
||||
const val core = "org.mapstruct:mapstruct:$version"
|
||||
const val processor = "org.mapstruct:mapstruct-processor:$version"
|
||||
}
|
||||
|
||||
object Micronaut {
|
||||
private const val version = "2.2.0"
|
||||
const val inject = "io.micronaut:micronaut-inject:$version"
|
||||
const val processor = "io.micronaut:micronaut-inject-java:$version"
|
||||
}
|
||||
|
||||
const val arrowCoreData = "io.arrow-kt:arrow-core-data:0.11.0"
|
||||
const val commonsCompress = "org.apache.commons:commons-compress:1.20"
|
||||
const val flexmark = "com.vladsch.flexmark:flexmark:0.62.2"
|
||||
const val flexmarkGfmTasklist = "com.vladsch.flexmark:flexmark-ext-gfm-tasklist:0.62.2"
|
||||
const val flywayCore = "org.flywaydb:flyway-core:6.5.4"
|
||||
const val h2 = "com.h2database:h2:1.4.200"
|
||||
const val hikariCP = "com.zaxxer:HikariCP:3.4.3"
|
||||
const val http4kCore = "org.http4k:http4k-core:3.268.0"
|
||||
const val javaJwt = "com.auth0:java-jwt:3.10.3"
|
||||
const val javaxServlet = "javax.servlet:javax.servlet-api:4.0.1"
|
||||
const val jbcrypt = "org.mindrot:jbcrypt:0.4"
|
||||
const val jettyServer = "org.eclipse.jetty:jetty-server:9.4.32.v20200930"
|
||||
const val jettyServlet = "org.eclipse.jetty:jetty-servlet:9.4.32.v20200930"
|
||||
const val konform = "io.konform:konform-jvm:0.2.0"
|
||||
const val kotlinxHtml = "org.jetbrains.kotlinx:kotlinx-html-jvm:0.7.1"
|
||||
const val kotlinxSerializationJson = "org.jetbrains.kotlinx:kotlinx-serialization-json-jvm:1.0.0"
|
||||
const val ktormCore = "me.liuwj.ktorm:ktorm-core:3.0.0"
|
||||
const val ktormMysql = "me.liuwj.ktorm:ktorm-support-mysql:3.0.0"
|
||||
const val logbackClassic = "ch.qos.logback:logback-classic:1.2.3"
|
||||
const val luceneAnalyzersCommon = "org.apache.lucene:lucene-analyzers-common:8.6.1"
|
||||
const val luceneCore = "org.apache.lucene:lucene-core:8.6.1"
|
||||
const val luceneQueryParser = "org.apache.lucene:lucene-queryparser:8.6.1"
|
||||
const val mapstruct = "org.mapstruct:mapstruct:1.4.1.Final"
|
||||
const val mapstructProcessor = "org.mapstruct:mapstruct-processor:1.4.1.Final"
|
||||
const val micronaut = "io.micronaut:micronaut-inject:2.1.2"
|
||||
const val micronautProcessor = "io.micronaut:micronaut-inject-java:2.1.2"
|
||||
const val mariadbClient = "org.mariadb.jdbc:mariadb-java-client:2.6.2"
|
||||
const val owaspHtmlSanitizer = "com.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizer:20200713.1"
|
||||
const val prettytime ="org.ocpsoft.prettytime:prettytime:4.0.5.Final"
|
||||
const val slf4jApi = "org.slf4j:slf4j-api:1.7.25"
|
||||
const val prettytime = "org.ocpsoft.prettytime:prettytime:4.0.5.Final"
|
||||
const val snakeyaml = "org.yaml:snakeyaml:1.26"
|
||||
|
||||
const val assertJ = "org.assertj:assertj-core:3.16.1"
|
||||
const val hamkrest = "com.natpryce:hamkrest:1.7.0.3"
|
||||
const val http4kTestingHamkrest = "org.http4k:http4k-testing-hamkrest:3.268.0"
|
||||
const val junit = "org.junit.jupiter:junit-jupiter:5.6.2"
|
||||
const val mockk = "io.mockk:mockk:1.10.0"
|
||||
const val faker = "com.github.javafaker:javafaker:1.0.2"
|
||||
const val mariaTestContainer = "org.testcontainers:mariadb:1.15.0-rc2"
|
||||
object Test {
|
||||
const val assertJ = "org.assertj:assertj-core:3.16.1"
|
||||
const val hamkrest = "com.natpryce:hamkrest:1.7.0.3"
|
||||
const val junit = "org.junit.jupiter:junit-jupiter:5.6.2"
|
||||
const val mockk = "io.mockk:mockk:1.10.0"
|
||||
const val faker = "com.github.javafaker:javafaker:1.0.2"
|
||||
const val mariaTestContainer = "org.testcontainers:mariadb:1.15.0-rc2"
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
27
buildSrc/src/main/kotlin/be/simplenotes/MicronautPlugin.kt
Normal file
27
buildSrc/src/main/kotlin/be/simplenotes/MicronautPlugin.kt
Normal file
@ -0,0 +1,27 @@
|
||||
package be.simplenotes
|
||||
|
||||
import org.gradle.api.Plugin
|
||||
import org.gradle.api.Project
|
||||
import org.gradle.api.artifacts.dsl.DependencyHandler
|
||||
|
||||
class MicronautPlugin : Plugin<Project> {
|
||||
override fun apply(target: Project) {
|
||||
target.plugins.apply("org.jetbrains.kotlin.kapt")
|
||||
}
|
||||
}
|
||||
|
||||
fun DependencyHandler.micronaut() {
|
||||
add("kapt", Libs.Micronaut.processor)
|
||||
add("implementation", Libs.Micronaut.inject)
|
||||
}
|
||||
|
||||
fun DependencyHandler.micronautTest() {
|
||||
add("kaptTest", Libs.Micronaut.processor)
|
||||
add("testImplementation", Libs.Micronaut.inject)
|
||||
}
|
||||
|
||||
fun DependencyHandler.micronautFixtures() {
|
||||
add("kaptTestFixtures", Libs.Micronaut.inject)
|
||||
add("testFixturesImplementation", Libs.Micronaut.processor)
|
||||
}
|
||||
|
||||
24
buildSrc/src/main/kotlin/be/simplenotes/PostcssPlugin.kt
Normal file
24
buildSrc/src/main/kotlin/be/simplenotes/PostcssPlugin.kt
Normal file
@ -0,0 +1,24 @@
|
||||
package be.simplenotes
|
||||
|
||||
import org.gradle.api.Plugin
|
||||
import org.gradle.api.Project
|
||||
import org.gradle.api.plugins.JavaPluginConvention
|
||||
import org.gradle.kotlin.dsl.get
|
||||
import org.gradle.kotlin.dsl.register
|
||||
import java.io.File
|
||||
|
||||
class PostcssPlugin : Plugin<Project> {
|
||||
override fun apply(project: Project) {
|
||||
with(project.tasks) {
|
||||
register<PostcssTask>("postcss") {
|
||||
group = "postcss"
|
||||
description = "generate postcss resources"
|
||||
}
|
||||
getByName("processResources").dependsOn("postcss")
|
||||
}
|
||||
|
||||
val sourceSets = project.convention.getPlugin(JavaPluginConvention::class.java).sourceSets
|
||||
val root = File("${project.buildDir}/generated-resources/css")
|
||||
sourceSets["main"].resources.srcDir(root)
|
||||
}
|
||||
}
|
||||
@ -9,9 +9,7 @@ import java.lang.ProcessBuilder.Redirect.PIPE
|
||||
import java.util.concurrent.TimeUnit
|
||||
import kotlin.concurrent.thread
|
||||
|
||||
open class CssTask : DefaultTask() {
|
||||
|
||||
private val root = project.parent!!.rootDir
|
||||
open class PostcssTask : DefaultTask() {
|
||||
|
||||
private val viewsProject = project
|
||||
.parent
|
||||
@ -54,7 +52,7 @@ open class CssTask : DefaultTask() {
|
||||
|
||||
outputRootDir.deleteRecursively()
|
||||
|
||||
ProcessBuilder("yarn", "run", "postcss", "build", "$cssIndex", "--output", "$cssOutput")
|
||||
ProcessBuilder("yarn", "run", "postcss", "$cssIndex", "--output", "$cssOutput")
|
||||
.apply {
|
||||
environment().let {
|
||||
it["MANIFEST"] = "$manifestOutput"
|
||||
@ -1,15 +0,0 @@
|
||||
package be.simplenotes
|
||||
|
||||
import org.gradle.kotlin.dsl.register
|
||||
|
||||
plugins {
|
||||
java apply false
|
||||
}
|
||||
|
||||
tasks.register<CssTask>("css")
|
||||
|
||||
sourceSets {
|
||||
val main by getting
|
||||
val root = file("$buildDir/generated-resources/css")
|
||||
main.resources.srcDir(root)
|
||||
}
|
||||
@ -1,23 +0,0 @@
|
||||
package be.simplenotes
|
||||
|
||||
tasks.create("dockerBuild") {
|
||||
dependsOn("package")
|
||||
|
||||
doLast {
|
||||
exec {
|
||||
commandLine("docker", "build", "-t", "hubv/simplenotes:latest", ".")
|
||||
workingDir(rootProject.projectDir)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
tasks.create("dockerPush") {
|
||||
dependsOn("dockerBuild")
|
||||
|
||||
doLast {
|
||||
exec {
|
||||
commandLine("docker", "push", "hubv/simplenotes:latest")
|
||||
workingDir(rootProject.projectDir)
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -30,7 +30,6 @@ tasks.create("package") {
|
||||
tasks.getByName("build").dependsOn("package")
|
||||
|
||||
dependsOn("shadowJar")
|
||||
dependsOn("css")
|
||||
|
||||
doLast {
|
||||
println("SimpleNotes Packaged !")
|
||||
|
||||
@ -5,5 +5,4 @@ plugins {
|
||||
id("be.simplenotes.kotlin-convention")
|
||||
id("be.simplenotes.junit-convention")
|
||||
id("org.jlleitschuh.gradle.ktlint")
|
||||
id("com.github.ben-manes.versions")
|
||||
}
|
||||
|
||||
@ -6,7 +6,6 @@ plugins {
|
||||
}
|
||||
|
||||
repositories {
|
||||
mavenLocal()
|
||||
mavenCentral()
|
||||
jcenter()
|
||||
maven { url = uri("https://dl.bintray.com/arrow-kt/arrow-kt/") }
|
||||
|
||||
@ -8,7 +8,6 @@ tasks.withType<Test> {
|
||||
useJUnitPlatform()
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
val test by getting
|
||||
test.resources.srcDir("${rootProject.projectDir}/testresources/src/test/resources")
|
||||
dependencies {
|
||||
testRuntimeOnly(project(":junit-config"))
|
||||
}
|
||||
|
||||
18
buildSrc/src/main/kotlin/be/simplenotes/versions.gradle.kts
Normal file
18
buildSrc/src/main/kotlin/be/simplenotes/versions.gradle.kts
Normal file
@ -0,0 +1,18 @@
|
||||
package be.simplenotes
|
||||
|
||||
import com.github.benmanes.gradle.versions.updates.DependencyUpdatesTask
|
||||
import org.gradle.kotlin.dsl.named
|
||||
|
||||
plugins {
|
||||
id("com.github.ben-manes.versions")
|
||||
}
|
||||
|
||||
tasks.named<DependencyUpdatesTask>("dependencyUpdates").configure {
|
||||
resolutionStrategy {
|
||||
componentSelection {
|
||||
all {
|
||||
if (candidate.module in listOf("slf4j-api", "logback-classic")) reject("Release candidate")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
implementation-class=be.simplenotes.DockerPlugin
|
||||
@ -0,0 +1 @@
|
||||
implementation-class=be.simplenotes.MicronautPlugin
|
||||
@ -0,0 +1 @@
|
||||
implementation-class=be.simplenotes.PostcssPlugin
|
||||
@ -1,11 +1,15 @@
|
||||
import be.simplenotes.Libs
|
||||
import be.simplenotes.micronaut
|
||||
|
||||
plugins {
|
||||
id("be.simplenotes.base")
|
||||
kotlin("kapt")
|
||||
id("be.simplenotes.micronaut")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(Libs.micronaut)
|
||||
kapt(Libs.micronautProcessor)
|
||||
micronaut()
|
||||
|
||||
testImplementation(Libs.Test.junit)
|
||||
testImplementation(Libs.Test.assertJ)
|
||||
testRuntimeOnly(Libs.Slf4J.logback)
|
||||
}
|
||||
|
||||
29
config/test/ConfigTest.kt
Normal file
29
config/test/ConfigTest.kt
Normal file
@ -0,0 +1,29 @@
|
||||
package be.simplenotes.config
|
||||
|
||||
import io.micronaut.context.ApplicationContext
|
||||
import org.assertj.core.api.Assertions.assertThat
|
||||
import org.junit.jupiter.api.Test
|
||||
|
||||
class ConfigTest {
|
||||
private val ctx = ApplicationContext.run()
|
||||
|
||||
@Test
|
||||
fun `check application yaml is on the classpath`() {
|
||||
val yaml = javaClass.getResource("/application.yaml")
|
||||
assertThat(yaml).`as`("The application.yaml resource").isNotNull
|
||||
assertThat(yaml.readText()).`as`("The config content").isNotBlank
|
||||
}
|
||||
|
||||
@Test
|
||||
fun `check config properties`() {
|
||||
assertThat(ctx.getProperty("jwt.validity", Int::class.java))
|
||||
.`as`("Jwt.validity")
|
||||
.isPresent
|
||||
}
|
||||
|
||||
@Test
|
||||
fun `load jwt config`() {
|
||||
val jwtConfig = ctx.getBean(JwtConfig::class.java)
|
||||
assertThat(jwtConfig).isNotNull
|
||||
}
|
||||
}
|
||||
14
config/testresources/logback.xml
Normal file
14
config/testresources/logback.xml
Normal file
@ -0,0 +1,14 @@
|
||||
<configuration>
|
||||
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<withJansi>true</withJansi>
|
||||
<encoder>
|
||||
<pattern>%cyan(%d{YYYY-MM-dd HH:mm:ss.SSS}) [%thread] %highlight(%-5level) %green(%logger{36}) - %msg%n
|
||||
</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
<root level="DEBUG">
|
||||
<appender-ref ref="STDOUT"/>
|
||||
</root>
|
||||
<logger name="io.micronaut" level="TRACE"/>
|
||||
<logger name="io.micronaut.context.lifecycle" level="TRACE"/>
|
||||
</configuration>
|
||||
4
css/build.gradle.kts
Normal file
4
css/build.gradle.kts
Normal file
@ -0,0 +1,4 @@
|
||||
plugins {
|
||||
id("be.simplenotes.java-convention")
|
||||
id("be.simplenotes.postcss")
|
||||
}
|
||||
@ -1,32 +1,33 @@
|
||||
import be.simplenotes.Libs
|
||||
import be.simplenotes.micronaut
|
||||
|
||||
plugins {
|
||||
id("be.simplenotes.base")
|
||||
id("be.simplenotes.kotlinx-serialization")
|
||||
kotlin("kapt")
|
||||
id("be.simplenotes.micronaut")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(project(":config"))
|
||||
implementation(project(":types"))
|
||||
api(project(":config"))
|
||||
api(project(":types"))
|
||||
implementation(project(":persistance"))
|
||||
implementation(project(":search"))
|
||||
|
||||
implementation(Libs.micronaut)
|
||||
kapt(Libs.micronautProcessor)
|
||||
api(Libs.arrowCoreData)
|
||||
api(Libs.konform)
|
||||
|
||||
implementation(Libs.kotlinxSerializationJson)
|
||||
implementation(Libs.arrowCoreData)
|
||||
implementation(Libs.konform)
|
||||
micronaut()
|
||||
|
||||
implementation(Libs.Kotlinx.Serialization.json)
|
||||
implementation(Libs.jbcrypt)
|
||||
implementation(Libs.javaJwt)
|
||||
implementation(Libs.flexmark)
|
||||
implementation(Libs.flexmarkGfmTasklist)
|
||||
implementation(Libs.Flexmark.core)
|
||||
implementation(Libs.Flexmark.tasklist)
|
||||
implementation(Libs.snakeyaml)
|
||||
implementation(Libs.owaspHtmlSanitizer)
|
||||
implementation(Libs.commonsCompress)
|
||||
|
||||
testImplementation(Libs.hamkrest)
|
||||
testImplementation(Libs.junit)
|
||||
testImplementation(Libs.mockk)
|
||||
testImplementation(Libs.Test.hamkrest)
|
||||
testImplementation(Libs.Test.junit)
|
||||
testImplementation(Libs.Test.mockk)
|
||||
}
|
||||
|
||||
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,5 +1,5 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8-rc-1-bin.zip
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
|
||||
3
junit-config/build.gradle.kts
Normal file
3
junit-config/build.gradle.kts
Normal file
@ -0,0 +1,3 @@
|
||||
plugins {
|
||||
id("be.simplenotes.java-convention")
|
||||
}
|
||||
@ -1,7 +1,10 @@
|
||||
import be.simplenotes.Libs
|
||||
import be.simplenotes.micronaut
|
||||
import be.simplenotes.micronautFixtures
|
||||
|
||||
plugins {
|
||||
id("be.simplenotes.base")
|
||||
id("be.simplenotes.micronaut")
|
||||
kotlin("kapt")
|
||||
`java-test-fixtures`
|
||||
}
|
||||
@ -10,43 +13,42 @@ dependencies {
|
||||
implementation(project(":types"))
|
||||
implementation(project(":config"))
|
||||
|
||||
implementation(Libs.mariadbClient)
|
||||
implementation(Libs.h2)
|
||||
implementation(Libs.flywayCore)
|
||||
implementation(Libs.hikariCP)
|
||||
implementation(Libs.ktormCore)
|
||||
implementation(Libs.ktormMysql)
|
||||
implementation(Libs.logbackClassic)
|
||||
implementation(Libs.Database.Drivers.mariadb)
|
||||
implementation(Libs.Database.Drivers.h2)
|
||||
implementation(Libs.Database.flyway)
|
||||
implementation(Libs.Database.hikariCP)
|
||||
implementation(Libs.Database.Ktorm.core)
|
||||
runtimeOnly(Libs.Database.Ktorm.mysql)
|
||||
|
||||
compileOnly(Libs.mapstruct)
|
||||
kapt(Libs.mapstructProcessor)
|
||||
implementation(Libs.Slf4J.api)
|
||||
runtimeOnly(Libs.Slf4J.logback)
|
||||
|
||||
implementation(Libs.micronaut)
|
||||
kapt(Libs.micronautProcessor)
|
||||
compileOnly(Libs.Mapstruct.core)
|
||||
kapt(Libs.Mapstruct.processor)
|
||||
|
||||
testImplementation(Libs.junit)
|
||||
testImplementation(Libs.assertJ)
|
||||
testImplementation(Libs.logbackClassic)
|
||||
testImplementation(Libs.mariaTestContainer)
|
||||
testImplementation(Libs.Test.junit)
|
||||
testImplementation(Libs.Test.assertJ)
|
||||
testCompileOnly(Libs.Slf4J.logback)
|
||||
testImplementation(Libs.Test.mariaTestContainer)
|
||||
|
||||
testFixturesImplementation(project(":types"))
|
||||
testFixturesImplementation(project(":config"))
|
||||
testFixturesImplementation(project(":persistance"))
|
||||
|
||||
testFixturesImplementation(Libs.micronaut)
|
||||
kaptTestFixtures(Libs.micronautProcessor)
|
||||
|
||||
testFixturesImplementation(Libs.faker) {
|
||||
testFixturesImplementation(Libs.Test.faker) {
|
||||
exclude(group = "org.yaml")
|
||||
}
|
||||
|
||||
testFixturesImplementation(Libs.snakeyaml)
|
||||
|
||||
testFixturesImplementation(Libs.mariaTestContainer)
|
||||
testFixturesImplementation(Libs.flywayCore)
|
||||
testFixturesImplementation(Libs.junit)
|
||||
testFixturesImplementation(Libs.ktormCore)
|
||||
testFixturesImplementation(Libs.hikariCP)
|
||||
testFixturesImplementation(Libs.Test.mariaTestContainer)
|
||||
testFixturesImplementation(Libs.Database.flyway)
|
||||
testFixturesImplementation(Libs.Test.junit)
|
||||
testFixturesImplementation(Libs.Database.Ktorm.core)
|
||||
testFixturesImplementation(Libs.Database.hikariCP)
|
||||
|
||||
micronaut()
|
||||
micronautFixtures()
|
||||
}
|
||||
|
||||
kotlin.sourceSets["testFixtures"].kotlin.srcDirs("testfixtures")
|
||||
|
||||
@ -1,21 +1,21 @@
|
||||
import be.simplenotes.Libs
|
||||
import be.simplenotes.micronaut
|
||||
|
||||
plugins {
|
||||
id("be.simplenotes.base")
|
||||
kotlin("kapt")
|
||||
id("be.simplenotes.micronaut")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(project(":types"))
|
||||
|
||||
implementation(Libs.luceneCore)
|
||||
implementation(Libs.luceneQueryParser)
|
||||
implementation(Libs.luceneAnalyzersCommon)
|
||||
implementation(Libs.slf4jApi)
|
||||
implementation(Libs.Lucene.core)
|
||||
implementation(Libs.Lucene.queryParser)
|
||||
implementation(Libs.Lucene.analyzersCommon)
|
||||
implementation(Libs.Slf4J.api)
|
||||
|
||||
implementation(Libs.micronaut)
|
||||
kapt(Libs.micronautProcessor)
|
||||
micronaut()
|
||||
|
||||
testImplementation(Libs.junit)
|
||||
testImplementation(Libs.assertJ)
|
||||
testImplementation(Libs.Test.junit)
|
||||
testImplementation(Libs.Test.assertJ)
|
||||
}
|
||||
|
||||
@ -6,3 +6,5 @@ include(":domain")
|
||||
include(":search")
|
||||
include(":types")
|
||||
include(":persistance")
|
||||
include(":css")
|
||||
include(":junit-config")
|
||||
|
||||
@ -6,5 +6,5 @@ plugins {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(Libs.kotlinxSerializationJson)
|
||||
implementation(Libs.Kotlinx.Serialization.json)
|
||||
}
|
||||
|
||||
@ -1,17 +1,17 @@
|
||||
import be.simplenotes.Libs
|
||||
import be.simplenotes.micronaut
|
||||
|
||||
plugins {
|
||||
id("be.simplenotes.base")
|
||||
kotlin("kapt")
|
||||
id("be.simplenotes.micronaut")
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(project(":types"))
|
||||
|
||||
implementation(Libs.konform)
|
||||
implementation(Libs.kotlinxHtml)
|
||||
implementation(Libs.prettytime)
|
||||
micronaut()
|
||||
|
||||
implementation(Libs.micronaut)
|
||||
kapt(Libs.micronautProcessor)
|
||||
implementation(Libs.konform)
|
||||
implementation(Libs.Kotlinx.html)
|
||||
implementation(Libs.prettytime)
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user