geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kl...@apache.org
Subject [38/50] [abbrv] incubator-geode git commit: GEODE-638: Add build task to allow for custom set of tests to be run
Date Fri, 11 Dec 2015 21:23:12 GMT
GEODE-638: Add build task to allow for custom set of tests to be run


Project: http://git-wip-us.apache.org/repos/asf/incubator-geode/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-geode/commit/a6398d91
Tree: http://git-wip-us.apache.org/repos/asf/incubator-geode/tree/a6398d91
Diff: http://git-wip-us.apache.org/repos/asf/incubator-geode/diff/a6398d91

Branch: refs/heads/feature/GEODE-217
Commit: a6398d919685d63c2bc89c1f4f605a5b73f3f257
Parents: eddef32
Author: Jens Deppe <jdeppe@pivotal.io>
Authored: Mon Dec 7 15:25:15 2015 -0800
Committer: Jens Deppe <jdeppe@pivotal.io>
Committed: Tue Dec 8 09:34:52 2015 -0800

----------------------------------------------------------------------
 build.gradle | 18 +++++++++++++++++-
 1 file changed, 17 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/a6398d91/build.gradle
----------------------------------------------------------------------
diff --git a/build.gradle b/build.gradle
index b5465b8..0c94573 100755
--- a/build.gradle
+++ b/build.gradle
@@ -386,7 +386,23 @@ subprojects {
     //I'm hoping this might deal with SOME OOMEs I've seen
     forkEvery 30
   }
-  
+
+  // By proving a file with an arbitrary list of test classes, we can select only those
+  // tests to run. Activated using -Dcustom.tests=<file> customTest
+  def customTestList = []
+  def customTestFile = System.getProperty('custom.tests')
+  if (customTestFile != null) {
+    new File(customTestFile).eachLine { customTestList << it }
+  }
+
+  task customTest(type:Test) {
+    include { x ->
+      (x.isDirectory() || customTestList.any { y -> x.getName().contains(y) } ) ? true
: false
+    }
+
+    forkEvery 30
+  }
+
   // apply common test configuration
   gradle.taskGraph.whenReady( { graph ->
     tasks.withType(Test).each { test ->


Mime
View raw message