mirror of https://github.com/apache/maven.git
o adding IT for mng-1927
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@367389 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
0542f670ab
commit
1636a473d5
|
@ -0,0 +1 @@
|
|||
target/classes/test.properties
|
|
@ -0,0 +1 @@
|
|||
test
|
|
@ -0,0 +1,23 @@
|
|||
<project>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.apache.maven.it</groupId>
|
||||
<artifactId>maven-core-it0088</artifactId>
|
||||
<version>1.0</version>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
<version>3.8.1</version>
|
||||
<type>jar</type>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<build>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>src/main/resources</directory>
|
||||
<filtering>true</filtering>
|
||||
</resource>
|
||||
</resources>
|
||||
</build>
|
||||
</project>
|
|
@ -0,0 +1 @@
|
|||
project.build.directory = ${project.build.directory}
|
|
@ -0,0 +1,35 @@
|
|||
package org.apache.maven.it0088;
|
||||
|
||||
import junit.framework.TestCase;
|
||||
|
||||
import java.util.Properties;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
|
||||
public class PomInterpolationTest
|
||||
extends TestCase
|
||||
{
|
||||
private String basedir;
|
||||
|
||||
protected void setUp()
|
||||
throws Exception
|
||||
{
|
||||
basedir = System.getProperty( "basedir" );
|
||||
}
|
||||
|
||||
public void testProjectBuildDirectory()
|
||||
throws Exception
|
||||
{
|
||||
Properties testProperties = new Properties();
|
||||
|
||||
File testPropertiesFile = new File( basedir, "target/classes/test.properties" );
|
||||
|
||||
assertTrue( testPropertiesFile.exists() );
|
||||
|
||||
testProperties.load( new FileInputStream( testPropertiesFile ) );
|
||||
|
||||
File projectBuildDirectory = new File( basedir, "target" );
|
||||
|
||||
assertEquals( testProperties.getProperty( "project.build.directory" ), projectBuildDirectory.getAbsolutePath() );
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue