Skip to content

Commit

Permalink
Update extension gradle plugin to 3.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
SgtSilvio committed Oct 6, 2023
1 parent 91d0cf0 commit dab8845
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 21 deletions.
39 changes: 21 additions & 18 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -20,24 +20,27 @@ hivemqExtension {
}
}

/* ******************** test ******************** */

dependencies {
testImplementation(libs.junit.jupiter)
testImplementation(libs.mockito)
}

tasks.withType<Test>().configureEach {
useJUnitPlatform()
}

/* ******************** integration test ******************** */

dependencies {
integrationTestImplementation(libs.hivemq.mqttClient)
integrationTestImplementation(libs.testcontainers.junitJupiter)
integrationTestImplementation(libs.testcontainers.hivemq)
integrationTestRuntimeOnly(libs.logback.classic)
@Suppress("UnstableApiUsage")
testing {
suites {
withType<JvmTestSuite> {
useJUnitJupiter(libs.versions.junit.jupiter)
}
"test"(JvmTestSuite::class) {
dependencies {
implementation(libs.mockito)
}
}
"integrationTest"(JvmTestSuite::class) {
dependencies {
compileOnly(libs.jetbrains.annotations)
implementation(libs.hivemq.mqttClient)
implementation(libs.testcontainers.junitJupiter)
implementation(libs.testcontainers.hivemq)
runtimeOnly(libs.logback.classic)
}
}
}
}

/* ******************** checks ******************** */
Expand Down
5 changes: 3 additions & 2 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
[versions]
hivemq-mqttClient = "1.3.1"
jetbrains-annotations = "24.0.1"
junit-jupiter = "5.9.3"
logback = "1.4.7"
mockito = "4.11.0"
testcontainers = "1.18.3"

[libraries]
hivemq-mqttClient = { module = "com.hivemq:hivemq-mqtt-client", version.ref = "hivemq-mqttClient" }
junit-jupiter = { module = "org.junit.jupiter:junit-jupiter", version.ref = "junit-jupiter" }
jetbrains-annotations = { module = "org.jetbrains:annotations", version.ref = "jetbrains-annotations" }
logback-classic = { module = "ch.qos.logback:logback-classic", version.ref = "logback" }
mockito = { module = "org.mockito:mockito-core", version.ref = "mockito" }
testcontainers-hivemq = { module = "org.testcontainers:hivemq", version.ref = "testcontainers" }
testcontainers-junitJupiter = { module = "org.testcontainers:junit-jupiter", version.ref = "testcontainers" }

[plugins]
hivemq-extension = { id = "com.hivemq.extension", version = "2.1.2" }
hivemq-extension = { id = "com.hivemq.extension", version = "3.0.0" }
defaults = { id = "io.github.sgtsilvio.gradle.defaults", version = "0.2.0" }
license = { id = "com.github.hierynomus.license", version = "0.16.1" }
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import com.hivemq.client.mqtt.mqtt5.Mqtt5BlockingClient;
import com.hivemq.client.mqtt.mqtt5.Mqtt5Client;
import com.hivemq.client.mqtt.mqtt5.message.publish.Mqtt5Publish;
import com.hivemq.extension.sdk.api.annotations.NotNull;
import org.jetbrains.annotations.NotNull;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Timeout;
import org.testcontainers.hivemq.HiveMQContainer;
Expand Down

0 comments on commit dab8845

Please sign in to comment.