Details
-
Type:
Improvement
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Component/s: None
-
Labels:None
-
Environment:Windows XP
-
Number of attachments :
Description
Summary
I have extended the maven-nunit-plugin to support the use of systemProperties. Unfortunately, as I am working from an in-house copy I can't easily make a patch file for you.
Significant Changes
1) Addition of new Properties class.
2) Several small changes within the NUnitEnvironment and NUnitMojo classes.
3) Upgrading org.codehaus.plexus:plexus-utils from version 1.0.4 to version 1.1 (necessary to gain some enhancements to the plexus Commandline class)
Unrelated Changes
1) Somewhat different POM inheritance since I'm using an in-house version. If you take the changes above, everything should work out.
Motivation
By combining this change to the maven-nunit-plugin with my change to the maven-exec-plugin (See MEXEC-4) its possible to create a cross-language integration test.
My C# based NUnit test can use the .NET Process class to execute "mvn exec:java" as part of a [TestFrameworkSetUp] annotated method in an nunit test. The exec:java goal within the C# code's POM just so happens to start up a java based server. (I actually have a little C# utility class to make this easy.) The nunit test methods can then perform integration tests requiring communication with the java server process. Upon completion of the tests a [TestFrameworkTearDown] annotated method in the nunit test can shut down the server process.
Example POM Snipt
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-nunit-plugin</artifactId>
<version>1.3.1.jpm</version>
<configuration>
<!--<inheritSystemProperties>true</inheritSystemProperties>-->
<systemProperties>
<systemProperty>
<key>basedir</key>
<value>${basedir}</value>
</systemProperty>
</systemProperties>
</configuration>
<!-- configuration>
<configFile>src/main/resources/App.config</configFile>
</configuration -->
</plugin>
Issue Links
- is related to
-
MSANDBOX-23
Dotnet Resources Support (code fix included)
-
reviewed and applied, thanks