You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

build.xml 2.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <?xml version="1.0"?>
  2. <project name="vaadin" basedir="." default="package" xmlns:ivy="antlib:org.apache.ivy.ant">
  3. <include file="common.xml" as="common" />
  4. <path id="vaadin.buildhelpers.classpath" location="${vaadin.basedir}/buildhelpers/result/classes" />
  5. <!-- =================================
  6. target: all
  7. ================================= -->
  8. <!--<target name="all" description="Compiles all parts of the project" depends="buildhelpers,theme-compiler,shared,server,client">-->
  9. <target name="package" description="Compiles and packages all modules in the project" depends="buildorder">
  10. <subant buildpathref="build-path" target="publish-local">
  11. </subant>
  12. </target>
  13. <target name="buildorder" depends="official.build.checks">
  14. <!-- Find out a good build order -->
  15. <ivy:buildlist reference="ivy.build.path">
  16. <fileset dir="." includes="**/build.xml">
  17. <exclude name="build.xml" />
  18. <exclude name="build/**" />
  19. <exclude name="buildhelpers/**" />
  20. </fileset>
  21. </ivy:buildlist>
  22. <path id="build-path">
  23. <path location="buildhelpers/build.xml"/>
  24. <path refid="ivy.build.path" />
  25. </path>
  26. </target>
  27. <target name="clean" depends="buildorder">
  28. <subant buildpathref="build-path" target="clean">
  29. </subant>
  30. <delete dir="result" />
  31. <!-- Clean IVY cache (~/.ivy2) so no old artifacts are fetched from there (leave everything but Vaadin artifacts) -->
  32. <delete dir="${ivy.cache.dir}/com.vaadin">
  33. </delete>
  34. </target>
  35. <target name="tests" depends="buildorder">
  36. <property name="war.file" location="result/artifacts/${vaadin.version}/vaadin-uitest/vaadin-uitest-${vaadin.version}.war" />
  37. <parallel>
  38. <sequential>
  39. <!-- Sleep before running integration tests so testbench tests have time to compile and start -->
  40. <sleep minutes="4" />
  41. <ant antfile="uitest/integration_tests.xml" target="integration-test-all" inheritall="false" inheritrefs="false">
  42. <property name="demo.war" value="${war.file}" />
  43. </ant>
  44. </sequential>
  45. <subant buildpathref="build-path" target="tests" />
  46. <ant antfile="uitest/test.xml" target="test-package">
  47. <property name="war.file" location="${war.file}" />
  48. </ant>
  49. </parallel>
  50. </target>
  51. <target name="official.build.checks" if="build.release">
  52. <condition property="java.version.matches">
  53. <equals arg1="${ant.java.version}" arg2="${vaadin.java.version}" />
  54. </condition>
  55. <fail unless="java.version.matches" message="Java version is ${ant.java.version}, but Vaadin must be compiled with genuine Java ${vaadin.java.version} compiler." />
  56. <echo>Java version is ${ant.java.version} as required.</echo>
  57. </target>
  58. </project>