You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by ep...@apache.org on 2004/07/08 15:06:15 UTC
cvs commit: maven-plugins/cruisecontrol/src/plugin-test project.xml project.properties maven.xml
epugh 2004/07/08 06:06:15
Added: cruisecontrol/src/plugin-test/cvs-scm project.xml maven.xml
cruisecontrol/src/plugin-test/svn-scm project.xml maven.xml
.cvsignore
cruisecontrol/src/plugin-test project.xml project.properties
maven.xml
Log:
New unit tests
Revision Changes Path
1.1 maven-plugins/cruisecontrol/src/plugin-test/cvs-scm/project.xml
Index: project.xml
===================================================================
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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>
<extend>${basedir}/../project.xml</extend>
<id>test-maven-cruisecontrol-cvs-plugin</id>
<name>Maven Cruisecontrol plugin test - cvs</name>
<repository>
<connection>scm:cvs:pserver:anoncvs@cvs.apache.org:/home/cvspublic:maven-plugins/cruisecontrol/src/plugin-test/cvs-scm</connection>
<url>http://cvs.apache.org/viewcvs/maven-plugins/cruisecontrol/src/plugin-test/cvs-scm</url>
</repository>
</project>
1.1 maven-plugins/cruisecontrol/src/plugin-test/cvs-scm/maven.xml
Index: maven.xml
===================================================================
<!--
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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 xmlns:j="jelly:core"
xmlns:assert="assert"
xmlns:u="jelly:util"
xmlns:x="jelly:xml"
xmlns:maven="jelly:maven"
xmlns:ant="jelly:ant">
<goal name="testPlugin" prereqs="test-init,test-cruisecontrol-configure,test-cruisecontrol-validate,test-cruisecontrol-jsl-file">
<attainGoal name="clean"/>
</goal>
<goal name="test-init">
</goal>
<goal name="test-cruisecontrol-configure">
<delete file="${maven.cruisecontrol.config}" failonerror="false"/>
<attainGoal name="cruisecontrol"/>
<assert:assertFileExists file="${maven.cruisecontrol.config}" />
<delete file="${maven.cruisecontrol.config}" failonerror="false"/>
<j:set var="maven.cruisecontrol.config" value="${basedir}/target/cc-temp.xml"/>
<attainGoal name="cruisecontrol"/>
<assert:assertFileExists file="${basedir}/target/cc-temp.xml" />
</goal>
<goal name="test-cruisecontrol-validate">
<attainGoal name="cruisecontrol:validate"/>
<j:set var="method" value="${context.getVariable('maven.scm.method')}"/>
<j:if test="${empty(method)}">
<ant:fail>method shouldn't be null</ant:fail>
</j:if>
</goal>
<goal name="test-cruisecontrol-jsl-file">
<attainGoal name="cruisecontrol"/>
<u:file var="cruisecontrolFile" name="${maven.cruisecontrol.config}"/>
<x:parse var="cruisecontrolDoc" xml="${cruisecontrolFile.toURL()}" />
<x:set var="count" select="count($cruisecontrolDoc/cruisecontrol/project/modificationset/cvs)"/>
<assert:assertEquals expected="1" value="${count.intValue().toString()}"/>
</goal>
</project>
1.1 maven-plugins/cruisecontrol/src/plugin-test/svn-scm/project.xml
Index: project.xml
===================================================================
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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>
<extend>${basedir}/../project.xml</extend>
<id>test-maven-cruisecontrol-svn-plugin</id>
<name>Maven Cruisecontrol plugin test - svn</name>
<repository>
<connection>scm:svn:http://someserver.com/:svn/dir/dir:</connection>
<url>http://cvs.apache.org/viewcvs/maven-plugins/cruisecontrol/src/plugin-test/svn-scm</url>
</repository>
</project>
1.1 maven-plugins/cruisecontrol/src/plugin-test/svn-scm/maven.xml
Index: maven.xml
===================================================================
<!--
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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 xmlns:j="jelly:core"
xmlns:assert="assert"
xmlns:u="jelly:util"
xmlns:x="jelly:xml"
xmlns:maven="jelly:maven"
xmlns:ant="jelly:ant">
<goal name="testPlugin" prereqs="test-init,test-cruisecontrol-configure,test-cruisecontrol-validate,test-cruisecontrol-jsl-file">
<attainGoal name="clean"/>
</goal>
<goal name="test-init">
</goal>
<goal name="test-cruisecontrol-configure">
<delete file="${maven.cruisecontrol.config}" failonerror="false"/>
<attainGoal name="cruisecontrol"/>
<assert:assertFileExists file="${maven.cruisecontrol.config}" />
<delete file="${maven.cruisecontrol.config}" failonerror="false"/>
<j:set var="maven.cruisecontrol.config" value="${basedir}/target/cc-temp.xml"/>
<attainGoal name="cruisecontrol"/>
<assert:assertFileExists file="${basedir}/target/cc-temp.xml" />
</goal>
<goal name="test-cruisecontrol-validate">
<attainGoal name="cruisecontrol:validate"/>
<j:set var="method" value="${context.getVariable('maven.scm.method')}"/>
<j:if test="${empty(method)}">
<ant:fail>method shouldn't be null</ant:fail>
</j:if>
</goal>
<goal name="test-cruisecontrol-jsl-file">
<attainGoal name="cruisecontrol"/>
<u:file var="cruisecontrolFile" name="${maven.cruisecontrol.config}"/>
<x:parse var="cruisecontrolDoc" xml="${cruisecontrolFile.toURL()}" />
<x:set var="count" select="count($cruisecontrolDoc/cruisecontrol/project/modificationset/svn)"/>
<assert:assertEquals expected="1" value="${count.intValue().toString()}"/>
</goal>
</project>
1.1 maven-plugins/cruisecontrol/src/plugin-test/svn-scm/.cvsignore
Index: .cvsignore
===================================================================
target
1.1 maven-plugins/cruisecontrol/src/plugin-test/project.xml
Index: project.xml
===================================================================
<?xml version="1.0" encoding="UTF-8"?>
<!--
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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>
<pomVersion>3</pomVersion>
<id>test-maven-cruisecontrol-plugin</id>
<name>Test project for Maven Cruisecontrol Plugin</name>
<groupId>maven</groupId>
<currentVersion>1.0-SNAPSHOT</currentVersion>
<organization>
<name>Apache Software Foundation</name>
<url>http://www.apache.org/</url>
<logo>http://maven.apache.org/images/jakarta-logo-blue.gif</logo>
</organization>
<inceptionYear>2001</inceptionYear>
<package>org.apache.maven</package>
<logo>http://maven.apache.org/images/maven.jpg</logo>
<description>Test for Maven CruiseControl plugin</description>
<shortDescription>Test for Maven CruiseControl plugin</shortDescription>
<url>http://maven.apache.org/reference/plugins/cruisecontrol/</url>
<siteDirectory>/www/maven.apache.org/reference/plugins/cruisecontrol/</siteDirectory>
<repository>
<connection>scm:cvs:pserver:anoncvs@cvs.apache.org:/home/cvspublic:maven-plugins/cruisecontrol/src/plugin-test</connection>
<url>http://cvs.apache.org/viewcvs/maven-plugins/cruisecontrol/src/plugin-test</url>
</repository>
<developers>
<developer>
<name>Eric Pugh</name>
<id>epugh</id>
<email>epugh@opensourceconnections.com</email>
<organization>OpenSource Connections</organization>
<roles>
<role>Developer</role>
</roles>
</developer>
</developers>
<dependencies>
<dependency>
<groupId>commons-jelly</groupId>
<artifactId>commons-jelly-tags-xml</artifactId>
<version>20030211.142705</version>
</dependency>
</dependencies>
<build>
<sourceDirectory>src/main</sourceDirectory>
<nagEmailAddress>epugh@opensourceconnections.com</nagEmailAddress>
</build>
</project>
1.1 maven-plugins/cruisecontrol/src/plugin-test/project.properties
Index: project.properties
===================================================================
# -------------------------------------------------------------------
# Copyright 2001-2004 The Apache Software Foundation.
#
# 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.
# -------------------------------------------------------------------
# MUST specify these, even though they are the defaults, so we can run inside reactor where they were already set
maven.multiproject.basedir=${basedir}
maven.multiproject.includes=*/project.xml
maven.multiproject.excludes=
1.1 maven-plugins/cruisecontrol/src/plugin-test/maven.xml
Index: maven.xml
===================================================================
<!--
/*
* Copyright 2001-2004 The Apache Software Foundation.
*
* 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 xmlns:util="jelly:util" xmlns:j="jelly:core">
<goal name="testPlugin">
<!-- Generate project artifacts -->
<j:set var="goal" value="testPlugin"/>
<attainGoal name="multiproject:goal"/>
</goal>
</project>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org