Răsfoiți Sursa

Allow IDEA test runner to control number of test iterations (#41653)

Allows configuring the number of test iterations via IntelliJ's config dialog, instead of having to add it
manually via the tests.iters system property.
Yannick Welsch 6 ani în urmă
părinte
comite
c9e8beb318

+ 6 - 1
server/src/main/resources/org/elasticsearch/bootstrap/test-framework.policy

@@ -89,6 +89,11 @@ grant codeBase "${codebase.httpasyncclient}" {
   permission java.net.NetPermission "getProxySelector";
 };
 
+grant codeBase "${codebase.junit-rt.jar}" {
+  // allows IntelliJ IDEA JUnit test runner to control number of test iterations
+  permission java.lang.reflect.ReflectPermission "suppressAccessChecks";
+};
+
 grant codeBase "file:${gradle.dist.lib}/-" {
   // gradle test worker code needs a slew of permissions, we give full access here since gradle isn't a production
   // dependency and there's no point in exercising the security policy against it
@@ -104,4 +109,4 @@ grant codeBase "file:${gradle.worker.jar}" {
 grant {
   // since the gradle test worker jar is on the test classpath, our tests should be able to read it
   permission java.io.FilePermission "${gradle.worker.jar}", "read";
-};
+};