view build.xml @ 956:1ba5cc4c9ca4 Hajipur-9.1.x

TW-46340 compute from revisions more correctly Endpoints should contain minimal set of uniteresting revisions. Now we don't add endpoint if it is already filtered out by another endpoint.
author Dmitry Neverov <dmitry.neverov@gmail.com>
date Fri, 22 Jul 2016 12:26:37 +0200
parents 31a1aca3305c
children
line wrap: on
line source
<!--
  ~ Copyright 2000-2014 JetBrains s.r.o.
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~ http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  -->

<project name="Mercurial VCS Support" default="dist" basedir=".">
  <property file="mercurial.properties"/>
  <import file="mercurial.xml"/>

  <property name="distPath" value="${basedir}/dist"/>

  <property name="plugin.name" value="mercurial"/>

  <property name="build.number" value=""/>
  <tstamp>
    <format property="timestamp" pattern="yyyyMMddhhmmss"/>
  </tstamp>
  <property name="snapshot.build.number" value="SNAPSHOT-${timestamp}"/>
  <property name="build.vcs.number" value=""/>

  <condition property="plugin.version" value="${snapshot.build.number}" else="${build.number}">
    <matches pattern="snapshot-.*" string="${build.number}" casesensitive="false"/>
  </condition>

  <import file="teamcity-common.xml"/>

  <target name="package" depends="define.version">
    <package.teamcity.plugin name="${plugin.name}"
                             server.output="${mercurial-server.output.dir}"
                             agent.output="${mercurial-agent.output.dir}"
                             common.output="${mercurial-common.output.dir}"
                             plugin.descriptor.file="${basedir}/teamcity-plugin.xml"
                             plugin.version="${plugin.version}"/>
  </target>

  <target name="define.version" depends="define.version.if.under.teamcity">
    <tstamp>
      <format property="current.time" pattern="yyyyMMddHHmm"/>
    </tstamp>
    <property name="plugin.version" value="SNAPSHOT-${current.time}"/>
  </target>

  <target name="define.version.if.under.teamcity" if="build.number">
    <property name="plugin.version" value="${build.number}"/>
  </target>

  <target name="dist" depends="check.teamcitydistribution,all,package"/>

  <target name="deploy" depends="dist">
    <deploy.teamcity.plugin name="${plugin.name}"/>
  </target>

  <taskdef name="testng" classname="org.testng.TestNGAntTask" classpath="${basedir}/mercurial-tests/lib/testng-5.7-jdk15.jar"/>

  <path id="tests_classpath">
    <pathelement location="${agent.home.dir}/lib/runtime-util.jar"/>
    <pathelement location="${agent.home.dir}/lib/buildServerRuntimeUtil.jar"/>
    <path refid="mercurial-tests.runtime.module.classpath"/>
  </path>

  <target name="run-tests" depends="clean, init, compile.module.mercurial-tests">
    <property name="suspend" value="n"/>

    <testng haltonfailure="no" failureProperty="failure_found" listener="org.testng.reporters.TestHTMLReporter"
            outputdir="${basedir}/test-output" classpathref="tests_classpath" dumpcommand="true" workingDir="${basedir}">

      <jvmarg value="-ea"/>
      <!--<jvmarg value="-Xrunjdwp:transport=dt_socket,server=y,suspend=${suspend},address=5555"/>-->

      <sysproperty key="java.awt.headless" value="true"/>

      <xmlfileset dir="${basedir}/mercurial-tests/src">
        <include name="testng.xml"/>
      </xmlfileset>
    </testng>
  </target>
</project>