Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .buildkite/scripts/run_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@ else
git checkout "$TARGET_BRANCH"
fi

./utils/ssl-certs-generator/generate.sh
chmod -R 0440 utils/ssl-certs-generator/generated/*
mkdir -p .ci && curl -sL --retry 5 --retry-delay 5 https://github.com/logstash-plugins/.ci/archive/1.x.tar.gz | tar zxvf - --skip-old-files --strip-components=1 -C .ci --wildcards '*Dockerfile*' '*docker*' '*.sh' '*logstash-versions*' && .ci/docker-setup.sh && .ci/docker-run.sh
2 changes: 1 addition & 1 deletion .ci/Dockerfile.elasticsearch
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ARG ES_SSL_SUPPORTED_PROTOCOLS

RUN rm -f $es_path/config/scripts

COPY --chown=elasticsearch:elasticsearch spec/fixtures/test_certs/* $es_path/config/test_certs/
COPY --chown=elasticsearch:elasticsearch utils/ssl-certs-generator/generated/* $es_path/config/test_certs/
COPY --chown=elasticsearch:elasticsearch .ci/elasticsearch-run.sh $es_path/

RUN if [ "$SECURE_INTEGRATION" != "true" ] ; then echo "xpack.security.enabled: false" >> $es_yml; fi
Expand Down
1 change: 0 additions & 1 deletion .ci/logstash-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,5 @@ else
echo "Waiting for elasticsearch to respond..."
ES_VERSION=$(wait_for_es)
echo "Elasticsearch $ES_VERSION is Up!"
chmod -R 0440 spec/fixtures/test_certs/*
bundle exec rspec --format=documentation $extra_tag_args --tag es_version:$ES_VERSION spec/integration
fi
18 changes: 10 additions & 8 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -104,15 +104,16 @@ dependencies {
from requiredLogstashCoreJar("guava", "jre")
})

mockitoAgent('org.mockito:mockito-core:5.14.1') {
mockitoAgent('org.mockito:mockito-core:5.23.0') {
transitive = false
}
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.1.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.1.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.14.1'
testImplementation 'org.hamcrest:hamcrest-library:2.2'
testImplementation "com.github.seregamorph:hamcrest-more-matchers:0.1"
testImplementation 'com.github.tomakehurst:wiremock-jre8:2.35.1'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.14.3'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.14.3'
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.14.3'
testImplementation 'org.mockito:mockito-junit-jupiter:5.23.0'
testImplementation 'org.hamcrest:hamcrest-library:3.0'
testImplementation "com.github.seregamorph:hamcrest-more-matchers:1.0"
testImplementation 'org.wiremock:wiremock:3.13.2'
testRuntimeOnly requiredLogstashCoreJar("log4j-core")

geolite2('org.elasticsearch:geolite2-databases:20191119') {
Expand Down Expand Up @@ -802,6 +803,7 @@ tasks.withType(JavaCompile) {

test {
useJUnitPlatform()
systemProperty 'ssl.test.certs.dir', "${projectDir}/utils/ssl-certs-generator/generated"
testLogging {
exceptionFormat "full"
outputs.upToDateWhen { false }
Expand All @@ -810,7 +812,7 @@ test {
}

task generateTestCertificates(type: Exec) {
def sslTestCertsDir = "${projectDir}/src/test/resources/co/elastic/logstash/filters/elasticintegration/ssl-test-certs"
def sslTestCertsDir = "${projectDir}/utils/ssl-certs-generator"

workingDir sslTestCertsDir
commandLine './generate.sh'
Expand Down
2 changes: 0 additions & 2 deletions spec/fixtures/test_certs/README.txt

This file was deleted.

Binary file removed spec/fixtures/test_certs/ca.p12
Binary file not shown.
67 changes: 0 additions & 67 deletions spec/fixtures/test_certs/client_from_root.chain.crt

This file was deleted.

35 changes: 0 additions & 35 deletions spec/fixtures/test_certs/client_from_root.crt

This file was deleted.

Binary file removed spec/fixtures/test_certs/client_from_root.jks
Binary file not shown.
51 changes: 0 additions & 51 deletions spec/fixtures/test_certs/client_from_root.key

This file was deleted.

53 changes: 0 additions & 53 deletions spec/fixtures/test_certs/client_from_root.key.pkcs8

This file was deleted.

Binary file removed spec/fixtures/test_certs/client_from_root.p12
Binary file not shown.
Loading
Loading