From: <bo...@us...> - 2013-04-25 15:15:02
|
Revision: 532 http://sourceforge.net/p/xmlunit/code/532 Author: bodewig Date: 2013-04-25 15:14:36 +0000 (Thu, 25 Apr 2013) Log Message: ----------- infrastructure for NUnit Constraints Modified Paths: -------------- trunk/xmlunit/xmlunit.nant.build Added Paths: ----------- trunk/xmlunit/src/main/net-constraints/ trunk/xmlunit/src/tests/net-constraints/ Modified: trunk/xmlunit/xmlunit.nant.build =================================================================== --- trunk/xmlunit/xmlunit.nant.build 2013-04-25 14:10:50 UTC (rev 531) +++ trunk/xmlunit/xmlunit.nant.build 2013-04-25 15:14:36 UTC (rev 532) @@ -21,10 +21,17 @@ <property name="core.src.dir" value="${base.dir}/src/main/net-core" overwrite="false"/> <property name="core.tests.src.dir" value="${base.dir}/src/tests/net-core" overwrite="false"/> + <property name="constraints.src.dir" value="${base.dir}/src/main/net-constraints" overwrite="false"/> + <property name="constraints.tests.src.dir" value="${base.dir}/src/tests/net-constraints" + overwrite="false"/> <property name="build.dir" value="${base.dir}/build/net" overwrite="false"/> <property name="gen.src.dir" value="${build.dir}/generated" overwrite="false"/> + <property name="gen.core.dir" value="${gen.src.dir}/core" + overwrite="false"/> + <property name="gen.constraints.dir" value="${gen.src.dir}/constraints" + overwrite="false"/> <property name="test.report.dir" value="${build.dir}/test-report"/> <property name="bin.dir" value="${build.dir}/bin" overwrite="false"/> @@ -39,7 +46,8 @@ value="lib" /> <target name="init" description="prepare for other targets"> - <mkdir dir="${gen.src.dir}"/> + <mkdir dir="${gen.core.dir}"/> + <mkdir dir="${gen.constraints.dir}"/> <mkdir dir="${bin.dir}"/> <copy file="${nunit.v2.bin.dir}/${nunit.v2.assembly}" tofile="${bin.dir}/${nunit.v2.assembly}"/> @@ -51,7 +59,7 @@ <target name="compile-core" description="compile core source files" depends="init"> - <asminfo output="${gen.src.dir}/AssemblyInfo.cs" language="CSharp"> + <asminfo output="${gen.core.dir}/AssemblyInfo.cs" language="CSharp"> <imports> <import namespace="System" /> <import namespace="System.Reflection" /> @@ -69,21 +77,56 @@ value="${project::get-name()}-core.tests, PublicKey=0024000004800000940000000602000000240000525341310004000001000100fdec9d5858956ff10ff9cf39935441a7d4a216475a467e951ddd8fcce0b74443696680a6cfb58f8b1d96166acb76f9eae0431a223cecb30e224c21f30e57c457747f6ba176e6c22f48e105b200b458509b6de815cccdfc9ebe59ae4024c4b8659d2f2fcb65b1688f8327b10c96ed7e5f536ba6a1978ae86aca438439efbd6cb6"/> </attributes> </asminfo> - <copy todir="${gen.src.dir}"> + <copy todir="${gen.core.dir}"> <fileset basedir="${core.src.dir}"> <include name="**/*.cs"/> </fileset> </copy> <csc target="library" output="${bin.dir}/${project::get-name()}-core.dll" debug="true" verbose="${csc.verbose}" keyfile="xmlunit.snk"> - <sources basedir="${gen.src.dir}"> + <sources basedir="${gen.core.dir}"> <include name="**/*.cs"/> </sources> </csc> </target> + <target name="compile-constraints" depends="compile-core" + description="compile constraints source files"> + <asminfo output="${gen.constraints.dir}/AssemblyInfo.cs" language="CSharp"> + <imports> + <import namespace="System" /> + <import namespace="System.Reflection" /> + <import namespace="System.Runtime.InteropServices" /> + <import namespace="System.Runtime.CompilerServices" /> + </imports> + <attributes> + <attribute type="ComVisibleAttribute" value="false"/> + <attribute type="CLSCompliantAttribute" value="true"/> + <attribute type="AssemblyVersionAttribute" value="${project.version4}"/> + <attribute type="AssemblyTitleAttribute" value="XMLUnit Constraints for NUnit" /> + <attribute type="AssemblyDescriptionAttribute" + value="Constraints Classes of XMLUnit for .NET" /> + <attribute type="InternalsVisibleToAttribute" + value="${project::get-name()}-constraints.tests, PublicKey=0024000004800000940000000602000000240000525341310004000001000100fdec9d5858956ff10ff9cf39935441a7d4a216475a467e951ddd8fcce0b74443696680a6cfb58f8b1d96166acb76f9eae0431a223cecb30e224c21f30e57c457747f6ba176e6c22f48e105b200b458509b6de815cccdfc9ebe59ae4024c4b8659d2f2fcb65b1688f8327b10c96ed7e5f536ba6a1978ae86aca438439efbd6cb6"/> + </attributes> + </asminfo> + <copy todir="${gen.constraints.dir}"> + <fileset basedir="${constraints.src.dir}"> + <include name="**/*.cs"/> + </fileset> + </copy> + <csc target="library" output="${bin.dir}/${project::get-name()}-constraints.dll" + debug="true" verbose="${csc.verbose}" keyfile="xmlunit.snk"> + <sources basedir="${gen.constraints.dir}"> + <include name="**/*.cs"/> + </sources> + </csc> + </target> + <target name="compile" description="compile all source files" - depends="compile-core"> + depends="compile-core,compile-constraints"/> + + <target name="compile-core-tests" depends="compile"> <csc target="library" output="${bin.dir}/${project::get-name()}-core.tests.dll" debug="true" verbose="${csc.verbose}" keyfile="xmlunit.snk"> @@ -97,11 +140,30 @@ </csc> </target> - <target name="test" description="run all tests" depends="compile"> + <target name="compile-constraints-tests" depends="compile-constraints"> + <!--csc target="library" + output="${bin.dir}/${project::get-name()}-constraints.tests.dll" + debug="true" verbose="${csc.verbose}" keyfile="xmlunit.snk"> + <references basedir="${bin.dir}"> + <include name="${project::get-name()}-core.dll"/> + <include name="${project::get-name()}-constraints.dll"/> + <include name="${nunit.v2.assembly}"/> + </references> + <sources basedir="${constraints.tests.src.dir}"> + <include name="**/*.cs"/> + </sources> + </csc--> + </target> + + <target name="compile-tests" + depends="compile-core-tests,compile-constraints-tests"/> + + <target name="test" description="run all tests" depends="compile-tests"> <nunit2> <formatter type="Plain"/> <formatter type="Xml" usefile="true" outputdir="${test.report.dir}"/> <test assemblyname="${bin.dir}/${project::get-name()}-core.tests.dll"/> + <!--test assemblyname="${bin.dir}/${project::get-name()}-constraints.tests.dll"/--> </nunit2> </target> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |