Merge pull request #14547 from rjernst/jvm_argline
Build: Add back support for tests.jvm.argline
This commit is contained in:
commit
faf2aeb9e8
|
@ -61,6 +61,11 @@ class RandomizedTestingTask extends DefaultTask {
|
||||||
ListenersConfiguration listenersConfig = new ListenersConfiguration(task: this)
|
ListenersConfiguration listenersConfig = new ListenersConfiguration(task: this)
|
||||||
|
|
||||||
List<String> jvmArgs = new ArrayList<>()
|
List<String> jvmArgs = new ArrayList<>()
|
||||||
|
|
||||||
|
@Optional
|
||||||
|
@Input
|
||||||
|
String argLine = null
|
||||||
|
|
||||||
Map<String, String> systemProperties = new HashMap<>()
|
Map<String, String> systemProperties = new HashMap<>()
|
||||||
PatternFilterable patternSet = new PatternSet()
|
PatternFilterable patternSet = new PatternSet()
|
||||||
|
|
||||||
|
@ -193,6 +198,9 @@ class RandomizedTestingTask extends DefaultTask {
|
||||||
for (String arg : jvmArgs) {
|
for (String arg : jvmArgs) {
|
||||||
jvmarg(value: arg)
|
jvmarg(value: arg)
|
||||||
}
|
}
|
||||||
|
if (argLine != null) {
|
||||||
|
jvmarg(line: argLine)
|
||||||
|
}
|
||||||
fileset(dir: testClassesDir) {
|
fileset(dir: testClassesDir) {
|
||||||
for (String includePattern : patternSet.getIncludes()) {
|
for (String includePattern : patternSet.getIncludes()) {
|
||||||
include(name: includePattern)
|
include(name: includePattern)
|
||||||
|
|
|
@ -111,6 +111,7 @@ class BuildPlugin implements Plugin<Project> {
|
||||||
File heapdumpDir = new File(project.buildDir, 'heapdump')
|
File heapdumpDir = new File(project.buildDir, 'heapdump')
|
||||||
heapdumpDir.mkdirs()
|
heapdumpDir.mkdirs()
|
||||||
jvmArg '-XX:HeapDumpPath=' + heapdumpDir
|
jvmArg '-XX:HeapDumpPath=' + heapdumpDir
|
||||||
|
argLine System.getProperty('tests.jvm.argline')
|
||||||
|
|
||||||
// we use './temp' since this is per JVM and tests are forbidden from writing to CWD
|
// we use './temp' since this is per JVM and tests are forbidden from writing to CWD
|
||||||
systemProperty 'java.io.tmpdir', './temp'
|
systemProperty 'java.io.tmpdir', './temp'
|
||||||
|
|
Loading…
Reference in New Issue