@@ -50,6 +50,8 @@ dependencies {
50
50
// HACK: javax.xml.bind was removed from default modules in java 9, so we pull the api in here,
51
51
// and whitelist this hack in JarHell
52
52
compile ' javax.xml.bind:jaxb-api:2.2.2'
53
+
54
+ testCompile project(' :test:fixtures:minio-fixture' )
53
55
}
54
56
55
57
dependencyLicenses {
@@ -105,10 +107,10 @@ boolean s3DisableChunkedEncoding = (new Random(Long.parseUnsignedLong(project.ro
105
107
// credentials hard-coded in.
106
108
107
109
if (! s3PermanentAccessKey && ! s3PermanentSecretKey && ! s3PermanentBucket && ! s3PermanentBasePath) {
108
- s3PermanentAccessKey = ' s3_integration_test_permanent_access_key '
109
- s3PermanentSecretKey = ' s3_integration_test_permanent_secret_key '
110
- s3PermanentBucket = ' permanent- bucket-test '
111
- s3PermanentBasePath = ' integration_test '
110
+ s3PermanentAccessKey = ' access_key '
111
+ s3PermanentSecretKey = ' secret_key '
112
+ s3PermanentBucket = ' bucket'
113
+ s3PermanentBasePath = ' '
112
114
113
115
useFixture = true
114
116
@@ -147,25 +149,10 @@ task thirdPartyTest(type: Test) {
147
149
if (useFixture) {
148
150
apply plugin : ' elasticsearch.test.fixtures'
149
151
150
- testFixtures. useFixture()
151
-
152
- task writeDockerFile {
153
- File minioDockerfile = new File (" ${ project.buildDir} /minio-docker/Dockerfile" )
154
- outputs. file(minioDockerfile)
155
- doLast {
156
- minioDockerfile. parentFile. mkdirs()
157
- minioDockerfile. text = " FROM minio/minio:RELEASE.2019-01-23T23-18-58Z\n " +
158
- " RUN mkdir -p /minio/data/${ s3PermanentBucket} \n " +
159
- " ENV MINIO_ACCESS_KEY ${ s3PermanentAccessKey} \n " +
160
- " ENV MINIO_SECRET_KEY ${ s3PermanentSecretKey} "
161
- }
162
- }
163
- preProcessFixture {
164
- dependsOn(writeDockerFile)
165
- }
152
+ testFixtures. useFixture(' :test:fixtures:minio-fixture' )
166
153
167
154
def minioAddress = {
168
- int minioPort = postProcessFixture. ext. " test.fixtures.minio-fixture.tcp.9000"
155
+ int minioPort = project( ' :test:fixtures:minio-fixture ' ) . postProcessFixture. ext. " test.fixtures.minio-fixture.tcp.9000"
169
156
assert minioPort > 0
170
157
' http://127.0.0.1:' + minioPort
171
158
}
@@ -178,13 +165,13 @@ if (useFixture) {
178
165
}
179
166
180
167
thirdPartyTest {
181
- dependsOn tasks. bundlePlugin, tasks . postProcessFixture
168
+ dependsOn tasks. bundlePlugin
182
169
nonInputProperties. systemProperty ' test.s3.endpoint' , " ${ -> minioAddress.call() } "
183
170
}
184
171
185
172
task integTestMinio(type : RestIntegTestTask ) {
186
173
description = " Runs REST tests using the Minio repository."
187
- dependsOn tasks. bundlePlugin, tasks . postProcessFixture
174
+ dependsOn tasks. bundlePlugin
188
175
runner {
189
176
// Minio only supports a single access key, see https://github.com/minio/minio/pull/5968
190
177
systemProperty ' tests.rest.blacklist' , [
0 commit comments