Skip to content

Commit fb6616c

Browse files
committed
allow env override of thread count #2373
1 parent 68028d2 commit fb6616c

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

karate-core/src/main/java/com/intuit/karate/Runner.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ public static class Builder<T extends Builder> {
9595
File workingDir;
9696
String buildDir;
9797
String configDir;
98-
int threadCount;
98+
int threadCount = 1;
9999
int timeoutMinutes;
100100
String reportDir;
101101
String scenarioName;
@@ -181,6 +181,9 @@ public List<FeatureCall> resolveAll() {
181181
if (ko.paths != null) {
182182
paths = ko.paths;
183183
}
184+
if (ko.threads != threadCount) { // 1 by default
185+
threadCount = ko.threads;
186+
}
184187
dryRun = ko.dryRun || dryRun;
185188
}
186189
String tempEnv = StringUtils.trimToNull(systemProperties.get(Constants.KARATE_ENV));

0 commit comments

Comments
 (0)