本文整理汇总了Java中org.codehaus.plexus.PlexusTestCase类的典型用法代码示例。如果您正苦于以下问题:Java PlexusTestCase类的具体用法?Java PlexusTestCase怎么用?Java PlexusTestCase使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
PlexusTestCase类属于org.codehaus.plexus包,在下文中一共展示了PlexusTestCase类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: MavenProjectBasicStub
import org.codehaus.plexus.PlexusTestCase; //导入依赖的package包/类
public MavenProjectBasicStub( String id )
throws Exception
{
// most values are hardcoded to have a controlled environment
super( new ModelStub() );
modelStub = (ModelStub) getModel();
properties = new Properties();
artifact = new ArtifactStub();
identifier = id;
// set isolated root directory
testRootDir = PlexusTestCase.getBasedir() + "/target/test-classes/unit/test-dir/" + identifier;
if ( !FileUtils.fileExists( testRootDir ) )
{
FileUtils.mkdir( testRootDir );
}
artifact.populate( this );
// this is ugly but needed to ensure that the copy constructor
// works correctly
initializeParentFields();
}
示例2: getBasedir
import org.codehaus.plexus.PlexusTestCase; //导入依赖的package包/类
/**
* @see org.apache.maven.project.MavenProject#getBasedir()
*/
public File getBasedir() {
File basedir = new File( PlexusTestCase.getBasedir(), "/target/test/unit/" + getProjectPath() + "/" );
if ( !basedir.exists() )
{
//noinspection ResultOfMethodCallIgnored
basedir.mkdirs();
}
return basedir;
}
示例3: getBasedir
import org.codehaus.plexus.PlexusTestCase; //导入依赖的package包/类
public File getBasedir()
{
return new File( PlexusTestCase.getBasedir() );
}
示例4: getTestProjectDir
import org.codehaus.plexus.PlexusTestCase; //导入依赖的package包/类
/**
* Returns the path to the directory containing test projects.
*/
private File getTestProjectDir()
{
return new File( PlexusTestCase.getBasedir(), "src/test/resources");
}
示例5: getBaseDir
import org.codehaus.plexus.PlexusTestCase; //导入依赖的package包/类
public File getBaseDir() {
return new File( PlexusTestCase.getBasedir() + "/src/test/resources/unit/spdx-maven-plugin-test/" );
}