Browse Source

Retry tests only run if create.retry.tests and retries are given

svn changeset:16597/svn branch:6.5
tags/6.7.0.beta1
Mikael Grankvist 13 years ago
parent
commit
4fc4227039
2 changed files with 16 additions and 14 deletions
  1. 4
    0
      build/build.xml
  2. 12
    14
      tests/test.xml

+ 4
- 0
build/build.xml View File

@@ -1188,6 +1188,10 @@
<!-- "tests" classes after unpacking the package. -->
<property name="output-dir" value="${output-dir}"/>

<!-- Convert some tests to run multiple times if failed. -->
<property name="create.retry.tests" value="1"/>
<property name="retries" value="3"/>
<property name="package.filename" value="${package.filename}"/>
<property name="testing.testarea" value="/tmp/testarea"/>
<property name="package.name" value="${package.name}"/>

+ 12
- 14
tests/test.xml View File

@@ -43,11 +43,13 @@
<exclude name="tests/integration-testscripts/**" />
</fileset>

<!-- fileset containing tests to retry -->
<fileset dir=".." id="html-retry-files-ie6">
<include name="tests/**/ComboBoxLargeIcons.html" />
</fileset>

<!-- This target converts HTML tests files to java junit tests. One test file for each browser is created. -->
<target name="create-tests" depends="remove-temp-testclasses" if="server.start.succeeded">
<fileset id="tests">
<include />
</fileset>
<pathconvert pathsep=" " property="testfiles" refid="html-test-files" />

<java classname="com.vaadin.testbench.util.TestConverter" classpathref="classpath">
@@ -57,21 +59,17 @@
</java>
</target>

<target name="create-retry-tests">

<target name="create-retry-tests" if="create.retry.tests">
<antcall target="convert-retry-test">
<param name="browser" value="winxp-ie6" />
<param name="testfile-name" value="tests/**/ComboBoxLargeIcons.html" />
<param name="retries" value="3" />
<param name="testfile-name" value="html-retry-files-ie6" />
</antcall>
</target>
<!-- Target converts test files so that the whole test can be re run 'retries' times -->
<target name="convert-retry-test">
<fail unless="retries" message="The 'retries' property must be defined." />
<fileset dir=".." id="test-files">
<include name="${testfile-name}" />
</fileset>
<pathconvert pathsep=" " property="testfile" refid="test-files" />
<target name="convert-retry-test" if="retries">
<pathconvert pathsep=" " property="testfile" refid="${testfile-name}" />

<java classname="com.vaadin.testbench.util.TestConverter" classpathref="classpath">
<sysproperty key="com.vaadin.testbench.test.retries" value="${retries}" />
@@ -212,4 +210,4 @@
<target name="test-package" depends="server-start, run-and-clean-up, server-stop">
</target>

</project>
</project>

Loading…
Cancel
Save