Changeset 35714 in osm


Ignore:
Timestamp:
2021-02-26T12:13:26+01:00 (4 years ago)
Author:
Don-vip
Message:

see #19724 - plugins build tuning

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/build-common.xml

    r35712 r35714  
    4747    <property name="ivy.jar.file"           location="${ivy.jar.dir}/ivy.jar"/>
    4848    <property name="ivy.version"            value="2.5.0"/>
     49    <property name="jacoco.inclbootstrapclasses"  value="false" />
     50    <property name="jacoco.inclnolocationclasses" value="false" />
     51    <property name="junit.printsummary"     value="on" />
    4952
    5053    <!-- For platform-specific stuff -->
     
    5962    <condition property="isJava13"><matches string="${ant.java.version}" pattern="1[3-9]" /></condition>
    6063    <condition property="isJava14"><matches string="${ant.java.version}" pattern="1[4-9]" /></condition>
     64    <condition property="isJava15"><matches string="${ant.java.version}" pattern="1[5-9]" /></condition>
    6165    <condition property="isJava16"><matches string="${ant.java.version}" pattern="1[6-9]" /></condition>
    62     <!-- Disable jacoco on Java 16+, see https://github.com/jacoco/jacoco/pull/992 -->
     66    <condition property="isJava18"><matches string="${ant.java.version}" pattern="1[8-9]" /></condition>
     67    <!-- Disable jacoco on Java 18+, see https://github.com/jacoco/jacoco/pull/1132 -->
    6368    <condition property="coverageByDefault">
    6469        <not>
    65             <isset property="isJava16"/>
     70            <isset property="isJava18"/>
    6671        </not>
    6772    </condition>
     
    117122            encoding="UTF-8" target="${java.lang.version}" source="${java.lang.version}" fork="yes">
    118123            <compilerarg value="-J-Xbootclasspath/p:${toString:jdk8.boot.classpath}" unless:set="isJava9"/>
    119             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    120             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    121             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    122             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    123             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    124             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    125             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    126             <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
    127             <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED" if:set="isJava16" unless:set="noErrorProne"/>
     124            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     125            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     126            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     127            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     128            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     129            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     130            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     131            <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
     132            <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED" if:set="isJava11" unless:set="noErrorProne"/>
    128133            <compilerarg line="-XDcompilePolicy=simple"/>
    129134            <compilerarg value="-processorpath"/>
     
    597602        <sequential>
    598603            <echo message="Running unit tests with JUnit"/>
    599             <jacoco:agent destfile="${plugin.test.dir}/jacoco.exec" enabled="${coverageByDefault}" property="jacocoagent"/>
    600             <junitlauncher printsummary="yes">
     604            <jacoco:agent destfile="${plugin.test.dir}/jacoco.exec" enabled="${coverageByDefault}" inclbootstrapclasses="${jacoco.inclbootstrapclasses}" inclnolocationclasses="${jacoco.inclnolocationclasses}" property="jacocoagent"/>
     605            <junitlauncher printsummary="${junit.printsummary}">
    601606                <classpath>
    602607                    <fileset refid="plugin.requires.jars"/>
     
    610615                        <jvmarg value="-Dfile.encoding=UTF-8"/>
    611616                        <jvmarg value="-javaagent:${jmockit.jar}"/>
     617                            <jvmarg value="-Djunit.jupiter.extensions.autodetection.enabled=true"/>
     618                            <jvmarg value="-Djunit.jupiter.execution.parallel.enabled=true"/>
    612619                        <jvmarg value="--add-modules" if:set="isJava9" unless:set="isJava11" />
    613620                        <jvmarg value="java.activation,java.se.ee" if:set="isJava9" unless:set="isJava11" />
     
    618625                        <jvmarg value="--add-exports" if:set="isJava9" />
    619626                        <jvmarg value="java.desktop/com.sun.imageio.spi=ALL-UNNAMED" if:set="isJava9" />
    620                         <jvmarg value="-XX:+ShowCodeDetailsInExceptionMessages" if:set="isJava14" />
     627                        <jvmarg value="-XX:+ShowCodeDetailsInExceptionMessages" if:set="isJava14" unless:set="isJava15" />
    621628                        <sysproperty key="josm.home" value="../00_core_test_config/unit-josm.home"/>
    622629                        <sysproperty key="josm.test.data" value="${plugin.test.dir}/data"/>
    623630                        <sysproperty key="java.awt.headless" value="true"/>
    624631                        <sysproperty key="suppressPermanentFailure" value="${suppressPermanentFailure}"/>
     632                            <sysproperty key="junit.jupiter.execution.parallel.enabled" value="${junit.jupiter.execution.parallel.enabled}" if:set="junit.jupiter.execution.parallel.enabled"/>
     633                            <sysproperty key="junit.jupiter.execution.parallel.mode.default" value="${junit.jupiter.execution.parallel.mode.default}" if:set="junit.jupiter.execution.parallel.mode.default"/>
     634                            <sysproperty key="junit.jupiter.execution.parallel.mode.classes.default" value="${junit.jupiter.execution.parallel.mode.classes.default}" if:set="junit.jupiter.execution.parallel.mode.classes.default"/>
    625635                        </fork>
    626636                    <listener type="legacy-plain" />
Note: See TracChangeset for help on using the changeset viewer.