Use /dev/urandom for tests.

This commit is contained in:
akwizgran
2018-08-20 16:54:46 +01:00
parent 65ce049737
commit b02d89967e
9 changed files with 31 additions and 9 deletions

View File

@@ -11,8 +11,8 @@ test:
- .gradle/caches
script:
- ./gradlew --no-daemon animalSnifferMain animalSnifferTest
- ./gradlew --no-daemon briar-core:test
- ./gradlew --no-daemon -Djava.security.egd=file:/dev/urandom animalSnifferMain animalSnifferTest
- ./gradlew --no-daemon -Djava.security.egd=file:/dev/urandom test
after_script:
# these file change every time but should not be cached

View File

@@ -55,3 +55,8 @@ project.afterEvaluate {
into 'src/main/res/raw'
}
}
tasks.withType(Test) {
// Use entropy-gathering device specified on command line, if any
systemProperty 'java.security.egd', System.getProperty('java.security.egd')
}

View File

@@ -31,3 +31,8 @@ task jarTest(type: Jar, dependsOn: testClasses) {
artifacts {
testOutput jarTest
}
tasks.withType(Test) {
// Use entropy-gathering device specified on command line, if any
systemProperty 'java.security.egd', System.getProperty('java.security.egd')
}

View File

@@ -44,3 +44,8 @@ task jarTest(type: Jar, dependsOn: testClasses) {
artifacts {
testOutput jarTest
}
tasks.withType(Test) {
// Use entropy-gathering device specified on command line, if any
systemProperty 'java.security.egd', System.getProperty('java.security.egd')
}

View File

@@ -26,5 +26,7 @@ dependencies {
}
tasks.withType(Test) {
// Use entropy-gathering device specified on command line, if any
systemProperty 'java.security.egd', System.getProperty('java.security.egd')
systemProperty 'java.library.path', 'libs'
}

View File

@@ -186,4 +186,7 @@ project.afterEvaluate {
preBuild.dependsOn.add(verifyTranslations)
}
tasks.withType(Test) {
// Use entropy-gathering device specified on command line, if any
systemProperty 'java.security.egd', System.getProperty('java.security.egd')
}

View File

@@ -11,3 +11,8 @@ dependencies {
signature 'org.codehaus.mojo.signature:java16:1.1@signature'
}
tasks.withType(Test) {
// Use entropy-gathering device specified on command line, if any
systemProperty 'java.security.egd', System.getProperty('java.security.egd')
}

View File

@@ -33,8 +33,7 @@ dependencies {
signature 'org.codehaus.mojo.signature:java16:1.1@signature'
}
test {
testLogging {
events "passed", "skipped", "failed", "standardOut", "standardError"
}
tasks.withType(Test) {
// Use entropy-gathering device specified on command line, if any
systemProperty 'java.security.egd', System.getProperty('java.security.egd')
}

View File

@@ -34,7 +34,6 @@ import org.briarproject.briar.api.introduction.event.IntroductionResponseReceive
import org.briarproject.briar.api.introduction.event.IntroductionSucceededEvent;
import org.briarproject.briar.test.BriarIntegrationTest;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import java.io.IOException;
@@ -71,7 +70,6 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
@Ignore
public class IntroductionIntegrationTest
extends BriarIntegrationTest<IntroductionIntegrationTestComponent> {