Skip to content

Commit

Permalink
Added Kotlin DSL examples (#379)
Browse files Browse the repository at this point in the history
Updated README with Kotlin DSL examples.
  • Loading branch information
mfvanek authored Oct 26, 2023
1 parent 4396a79 commit 36f2d3b
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,24 @@ dependencies {
}
```

<details>
<summary>with Kotlin DSL</summary>

```kotlin
repositories {
mavenCentral()
// maven("https://repo.spring.io/milestone")
// maven("https://repo.spring.io/snapshot")
}

dependencies {
testImplementation("io.projectreactor.tools:blockhound:$LATEST_RELEASE")
// testImplementation("io.projectreactor.tools:blockhound:$LATEST_MILESTONE")
// testImplementation("io.projectreactor.tools:blockhound:$LATEST_SNAPSHOT")
}
```
</details>

_Maven_

```xml
Expand Down Expand Up @@ -104,6 +122,18 @@ _Gradle_
}
```

<details>
<summary>with Kotlin DSL</summary>

```kotlin
tasks.withType<Test>().all {
if (JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_13)) {
jvmArgs("-XX:+AllowRedefinitionToAddDeleteMethods")
}
}
```
</details>

## Built-in integrations
Although BlockHound supports [the SPI mechanism to integrate with](https://github.com/reactor/BlockHound/blob/master/docs/custom_integrations.md), it comes with a few built-in integrations:
1. [Project Reactor](https://projectreactor.io)
Expand Down

0 comments on commit 36f2d3b

Please sign in to comment.