Skip to content

Commit 6523069

Browse files
authored
Merge branch 'main' into test-java-versions
2 parents 3adf53e + 88e4ac5 commit 6523069

File tree

118 files changed

+2474
-282
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

118 files changed

+2474
-282
lines changed

.github/ISSUE_TEMPLATE/feature.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ body:
8484
id: benefit
8585
attributes:
8686
label: Benefit
87-
description: What's the benefit of addng this feature to the project?
87+
description: What's the benefit of adding this feature to the project?
8888
validations:
8989
required: true
9090
- type: textarea

.github/dependabot.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ updates:
2222
update-types: [ "version-update:semver-minor", "version-update:semver-patch" ]
2323
- dependency-name: "org.apache.commons:commons-compress"
2424
update-types: [ "version-update:semver-minor" ]
25+
- dependency-name: "org.awaitility:awaitility"
26+
update-types: [ "version-update:semver-patch" ]
2527
- package-ecosystem: "gradle"
2628
directory: "/"
2729
allow:
@@ -76,6 +78,9 @@ updates:
7678
schedule:
7779
interval: "weekly"
7880
open-pull-requests-limit: 10
81+
ignore:
82+
- dependency-name: "org.awaitility:awaitility"
83+
update-types: [ "version-update:semver-patch" ]
7984
- package-ecosystem: "gradle"
8085
directory: "/modules/cratedb"
8186
schedule:
@@ -121,6 +126,9 @@ updates:
121126
schedule:
122127
interval: "weekly"
123128
open-pull-requests-limit: 10
129+
ignore:
130+
- dependency-name: "com.influxdb:influxdb-java-client"
131+
update-types: [ "version-update:semver-major" ]
124132
- package-ecosystem: "gradle"
125133
directory: "/modules/jdbc"
126134
schedule:
@@ -277,6 +285,9 @@ updates:
277285
schedule:
278286
interval: "weekly"
279287
open-pull-requests-limit: 10
288+
ignore:
289+
- dependency-name: "org.awaitility:awaitility"
290+
update-types: [ "version-update:semver-patch" ]
280291
- package-ecosystem: "gradle"
281292
directory: "/modules/r2dbc"
282293
schedule:
@@ -311,6 +322,8 @@ updates:
311322
ignore:
312323
- dependency-name: "org.apache.qpid:qpid-jms-client"
313324
update-types: [ "version-update:semver-major" ]
325+
- dependency-name: "org.awaitility:awaitility"
326+
update-types: [ "version-update:semver-patch" ]
314327
- package-ecosystem: "gradle"
315328
directory: "/modules/solr"
316329
schedule:
@@ -376,6 +389,8 @@ updates:
376389
update-types: [ "version-update:semver-major" ]
377390
- dependency-name: "com.diffplug.spotless"
378391
update-types: [ "version-update:semver-minor" ]
392+
- dependency-name: "com.hazelcast:hazelcast"
393+
update-types: [ "version-update:semver-minor" ]
379394

380395
# Smoke test
381396
- package-ecosystem: "gradle"

.github/workflows/ci-windows.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: CI - Windows
2+
3+
on:
4+
pull_request:
5+
paths-ignore:
6+
- '.github/ISSUE_TEMPLATE/*.yaml'
7+
- '.github/CODEOWNERS'
8+
- '.github/pull_request_template.md'
9+
- 'docs/**/*.css'
10+
- 'docs/**/*.html'
11+
- 'docs/**/*.ico'
12+
- 'docs/**/*.md'
13+
- 'docs/**/*.png'
14+
- 'docs/**/*.svg'
15+
- 'mkdocs.yml'
16+
- 'README.md'
17+
- 'RELEASING.md'
18+
- '.sdkmanrc'
19+
push:
20+
branches: [ main ]
21+
paths-ignore:
22+
- '.github/ISSUE_TEMPLATE/*.yaml'
23+
- '.github/CODEOWNERS'
24+
- '.github/pull_request_template.md'
25+
- 'docs/**/*.css'
26+
- 'docs/**/*.html'
27+
- 'docs/**/*.ico'
28+
- 'docs/**/*.md'
29+
- 'docs/**/*.png'
30+
- 'docs/**/*.svg'
31+
- 'mkdocs.yml'
32+
- 'README.md'
33+
- 'RELEASING.md'
34+
- '.sdkmanrc'
35+
36+
concurrency:
37+
group: "${{ github.workflow }}-${{ github.head_ref || github.sha }}"
38+
cancel-in-progress: true
39+
40+
permissions:
41+
contents: read
42+
43+
jobs:
44+
core:
45+
runs-on: self-hosted
46+
permissions:
47+
checks: write
48+
steps:
49+
- uses: actions/checkout@v4
50+
- name: Build with Gradle
51+
run: ./gradlew.bat cleanTest testcontainers:test --no-daemon --continue --scan --no-build-cache
52+
- uses: ./.github/actions/setup-junit-report

.github/workflows/combine-prs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ jobs:
1313
steps:
1414
- name: combine-prs
1515
id: combine-prs
16-
uses: github/combine-prs@v5.0.0
16+
uses: github/combine-prs@v5.1.0
1717
with:
1818
github_token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/update-docs-version.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
sed -i "s/latest_version: .*/latest_version: ${GITHUB_REF##*/}/g" mkdocs.yml
2424
git diff
2525
- name: Create Pull Request
26-
uses: peter-evans/create-pull-request@6d6857d36972b65feb161a90e484f2984215f83e # v3.10.1
26+
uses: peter-evans/create-pull-request@c5a7806660adbe173f04e3e038b0ccdcd758773c # v3.10.1
2727
with:
2828
title: Update docs version to ${GITHUB_REF##*/}
2929
body: |

.github/workflows/update-testcontainers-version.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
sed -i "s/^testcontainers\.version=.*/testcontainers\.version=${GITHUB_REF##*/}/g" gradle.properties
2424
git diff
2525
- name: Create Pull Request
26-
uses: peter-evans/create-pull-request@6d6857d36972b65feb161a90e484f2984215f83e # v3.10.1
26+
uses: peter-evans/create-pull-request@c5a7806660adbe173f04e3e038b0ccdcd758773c # v3.10.1
2727
with:
2828
title: Update testcontainers version to ${GITHUB_REF##*/}
2929
body: |

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ buildscript {
55

66
dependencies {
77
// https://github.com/melix/japicmp-gradle-plugin/issues/36
8-
classpath 'com.google.guava:guava:32.1.2-jre'
8+
classpath 'com.google.guava:guava:33.2.1-jre'
99
classpath 'com.github.tjni.captainhook:captain-hook:0.1.5'
1010
}
1111
}
1212

1313
plugins {
1414
id 'io.franzbecker.gradle-lombok' version '5.0.0'
1515
id 'com.github.johnrengelman.shadow' version '8.1.1'
16-
id 'me.champeau.gradle.japicmp' version '0.4.2' apply false
16+
id 'me.champeau.gradle.japicmp' version '0.4.3' apply false
1717
id 'com.diffplug.spotless' version '6.22.0' apply false
1818
}
1919

core/build.gradle

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ dependencies {
8686
exclude group: 'org.apache.commons', module: 'commons-compress'
8787
}
8888

89-
shaded 'org.awaitility:awaitility:4.2.1'
89+
shaded 'org.awaitility:awaitility:4.2.0'
9090

9191
api platform('com.github.docker-java:docker-java-bom:3.4.0')
9292
shaded platform('com.github.docker-java:docker-java-bom:3.4.0')
@@ -99,7 +99,7 @@ dependencies {
9999

100100
api 'com.github.docker-java:docker-java-transport-zerodep'
101101

102-
shaded 'com.google.guava:guava:33.2.0-jre'
102+
shaded 'com.google.guava:guava:33.2.1-jre'
103103
shaded "org.yaml:snakeyaml:1.33"
104104

105105
shaded 'org.glassfish.main.external:trilead-ssh2-repackaged:4.1.2'
@@ -120,13 +120,13 @@ dependencies {
120120
// Synthetic JAR used for MountableFileTest and DirectoryTarResourceTest
121121
testImplementation files('testlib/repo/fakejar/fakejar/0/fakejar-0.jar')
122122

123-
testImplementation 'org.assertj:assertj-core:3.25.3'
124-
testImplementation 'io.rest-assured:rest-assured:5.4.0'
123+
testImplementation 'org.assertj:assertj-core:3.26.3'
124+
testImplementation 'io.rest-assured:rest-assured:5.5.0'
125125

126126
jarFileTestCompileOnly "org.projectlombok:lombok:${lombok.version}"
127127
jarFileTestAnnotationProcessor "org.projectlombok:lombok:${lombok.version}"
128128
jarFileTestImplementation 'junit:junit:4.13.2'
129-
jarFileTestImplementation 'org.assertj:assertj-core:3.25.3'
129+
jarFileTestImplementation 'org.assertj:assertj-core:3.26.3'
130130
jarFileTestImplementation 'org.ow2.asm:asm-debug-all:5.2'
131131
}
132132

core/src/jarFileTest/java/org/testcontainers/AbstractJarFileTest.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
package org.testcontainers;
22

33
import java.net.URI;
4+
import java.net.URLDecoder;
5+
import java.nio.charset.StandardCharsets;
46
import java.nio.file.FileSystem;
57
import java.nio.file.FileSystems;
68
import java.nio.file.Path;
@@ -14,7 +16,8 @@ public abstract class AbstractJarFileTest {
1416
static {
1517
try {
1618
Path jarFilePath = Paths.get(System.getProperty("jarFile"));
17-
URI jarFileUri = new URI("jar", jarFilePath.toUri().toString(), null);
19+
String decodedPath = URLDecoder.decode(jarFilePath.toUri().toString(), StandardCharsets.UTF_8.name());
20+
URI jarFileUri = new URI("jar", decodedPath, null);
1821
FileSystem fileSystem = FileSystems.newFileSystem(jarFileUri, Collections.emptyMap());
1922
root = fileSystem.getPath("/");
2023
} catch (Exception e) {

core/src/main/java/org/testcontainers/DockerClientFactory.java

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
import java.io.InputStream;
3434
import java.net.URI;
3535
import java.util.ArrayList;
36+
import java.util.Arrays;
3637
import java.util.Collections;
3738
import java.util.HashMap;
3839
import java.util.List;
@@ -41,6 +42,7 @@
4142
import java.util.UUID;
4243
import java.util.function.BiFunction;
4344
import java.util.function.Consumer;
45+
import java.util.stream.Collectors;
4446

4547
/**
4648
* Singleton class that provides initialized Docker clients.
@@ -210,7 +212,8 @@ public void close() {
210212
Version version = client.versionCmd().exec();
211213
log.debug("Docker version: {}", version.getRawValues());
212214
activeApiVersion = version.getApiVersion();
213-
log.info(
215+
216+
String serverInfo =
214217
"Connected to docker: \n" +
215218
" Server Version: " +
216219
dockerInfo.getServerVersion() +
@@ -224,8 +227,18 @@ public void close() {
224227
" Total Memory: " +
225228
dockerInfo.getMemTotal() /
226229
(1024 * 1024) +
227-
" MB"
228-
);
230+
" MB";
231+
232+
String[] labels = dockerInfo.getLabels();
233+
boolean hasLabels = labels != null && labels.length > 0;
234+
if (hasLabels) {
235+
String formattedLabels = Arrays
236+
.stream(labels)
237+
.map(label -> " " + label)
238+
.collect(Collectors.joining("\n"));
239+
serverInfo += "\n Labels: \n" + formattedLabels;
240+
}
241+
log.info(serverInfo);
229242

230243
try {
231244
//noinspection deprecation

0 commit comments

Comments
 (0)