mirror of https://github.com/apache/lucene.git
LUCENE-5881: Add "beasting" of tests: repeats the whole "test" Ant target N times with "ant beast -Dbeast.iters=N"
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1617078 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
38749091b4
commit
a546284628
|
@ -237,14 +237,18 @@ Bug Fixes
|
|||
would be exceeded, instead of silently creating an unusable
|
||||
index. (Mike McCandless)
|
||||
|
||||
* LUCENE-5869: Added restriction to positive values for maxExpansions in FuzzyQuery.
|
||||
(Ryan Ernst)
|
||||
* LUCENE-5869: Added restriction to positive values for maxExpansions in
|
||||
FuzzyQuery. (Ryan Ernst)
|
||||
|
||||
Test Framework
|
||||
|
||||
* LUCENE-5786: Unflushed/ truncated events file (hung testing subprocess).
|
||||
(Dawid Weiss)
|
||||
|
||||
* LUCENE-5881: Add "beasting" of tests: repeats the whole "test" Ant target
|
||||
N times with "ant beast -Dbeast.iters=N". (Uwe Schindler, Robert Muir,
|
||||
Ryan Ernst, Dawid Weiss)
|
||||
|
||||
Build
|
||||
|
||||
* LUCENE-5770: Upgrade to JFlex 1.6, which has direct support for
|
||||
|
|
|
@ -1147,7 +1147,7 @@
|
|||
</target>
|
||||
|
||||
<target name="test-help" description="Help on 'ant test' syntax.">
|
||||
<echo>
|
||||
<echo taskname="help">
|
||||
#
|
||||
# Test case filtering. --------------------------------------------
|
||||
#
|
||||
|
@ -1202,6 +1202,15 @@ ant test -Dtests.iters=N -Dtests.maxfailures=M -Dtestcase=...
|
|||
# in parallel.
|
||||
ant test -Dtests.dups=N ...
|
||||
|
||||
# Test beasting: Repeats every suite with same seed per class
|
||||
# (N times in parallel) and each test inside (M times). The whole
|
||||
# run is repeated (beasting) P times in a loop, with a different
|
||||
# master seed. You can combine beasting with any other parameter,
|
||||
# just replace "test" with "beast" and give -Dbeast.iters=P
|
||||
# (P >> 1).
|
||||
ant test -Dtests.dups=N -Dtests.iters=M -Dbeast.iters=P \
|
||||
-Dtestcase=ClassName beast
|
||||
|
||||
#
|
||||
# Test groups. ----------------------------------------------------
|
||||
#
|
||||
|
@ -1289,8 +1298,8 @@ ${tests-output}/junit4-*.suites - per-JVM executed suites
|
|||
|
||||
<!-- note: order here is important, the taskdef depends on test-framework
|
||||
jars so we just order it after compile-test to ensure that -->
|
||||
<target name="test" depends="clover,compile-test,install-junit4-taskdef,validate,-init-totals,-test,-check-totals" description="Runs unit tests">
|
||||
</target>
|
||||
<target name="test" depends="clover,compile-test,install-junit4-taskdef,validate,-init-totals,-test,-check-totals" description="Runs unit tests"/>
|
||||
<target name="beast" depends="clover,compile-test,install-junit4-taskdef,validate,-init-totals,-beast,-check-totals" description="Runs unit tests in a loop (-Dbeast.iters=n)"/>
|
||||
|
||||
<!-- Run the actual tests (must be wrapped with -init-totals, -check-totals) -->
|
||||
<target name="-test">
|
||||
|
@ -1298,6 +1307,22 @@ ${tests-output}/junit4-*.suites - per-JVM executed suites
|
|||
<test-macro threadNum="${tests.jvms.override}" />
|
||||
</target>
|
||||
|
||||
<!-- Beast the actual tests (must be wrapped with -init-totals, -check-totals) -->
|
||||
<target name="-beast" depends="resolve-groovy">
|
||||
<groovy taskname="beaster"><![CDATA[
|
||||
int iters = (properties['beast.iters'] ?: '1') as int;
|
||||
def antcall = project.createTask('antcall');
|
||||
antcall.target = '-test';
|
||||
antcall.inheritAll = true;
|
||||
antcall.inheritRefs = true;
|
||||
(1..iters).each { i ->
|
||||
task.log('Beast round: ' + i);
|
||||
antcall.execute();
|
||||
};
|
||||
task.log('Beasting finished.');
|
||||
]]></groovy>
|
||||
</target>
|
||||
|
||||
<target name="-check-totals" if="tests.totals.toplevel" depends="resolve-groovy">
|
||||
<!-- We are concluding a test pass at the outermost level. Sum up all executed tests. -->
|
||||
<groovy><![CDATA[
|
||||
|
@ -1315,7 +1340,7 @@ ${tests-output}/junit4-*.suites - per-JVM executed suites
|
|||
}
|
||||
|
||||
// Interesting but let's keep the build output quiet.
|
||||
// project.log("Grand total of all executed tests (including sub-modules): " + total);
|
||||
// task.log("Grand total of all executed tests (including sub-modules): " + total);
|
||||
]]></groovy>
|
||||
</target>
|
||||
|
||||
|
|
Loading…
Reference in New Issue