当前位置: 首页>>代码示例>>Java>>正文


Java JavaModuleFixtureBuilder.addLibrary方法代码示例

本文整理汇总了Java中com.intellij.testFramework.builders.JavaModuleFixtureBuilder.addLibrary方法的典型用法代码示例。如果您正苦于以下问题:Java JavaModuleFixtureBuilder.addLibrary方法的具体用法?Java JavaModuleFixtureBuilder.addLibrary怎么用?Java JavaModuleFixtureBuilder.addLibrary使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.intellij.testFramework.builders.JavaModuleFixtureBuilder的用法示例。


在下文中一共展示了JavaModuleFixtureBuilder.addLibrary方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setUp

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@BeforeMethod
public void setUp() throws Exception {
  JavaTestFixtureFactory.getFixtureFactory();   // registers Java module fixture builder
  final IdeaTestFixtureFactory fixtureFactory = IdeaTestFixtureFactory.getFixtureFactory();
  final TestFixtureBuilder<IdeaProjectTestFixture> testFixtureBuilder = fixtureFactory.createFixtureBuilder(getClass().getSimpleName());
  myFixture = fixtureFactory.createTempDirTestFixture();
  myFixture.setUp();

  FileUtil.copyDir(new File(PluginPathManager.getPluginHomePath("testng") + "/testData/runConfiguration/module1"),
                   new File(myFixture.getTempDirPath()), false);

  myProjectFixture = testFixtureBuilder.getFixture();
  final JavaModuleFixtureBuilder javaModuleFixtureBuilder = testFixtureBuilder.addModule(JavaModuleFixtureBuilder.class);
  javaModuleFixtureBuilder.addContentRoot(myFixture.getTempDirPath()).addSourceRoot("src");
  javaModuleFixtureBuilder.addLibrary("testng", PathUtil.getJarPathForClass(AfterMethod.class));
  myProjectFixture.setUp();

}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:19,代码来源:ConfigurationsTest.java

示例2: setUp

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@BeforeMethod
public void setUp() throws Exception {
  JavaTestFixtureFactory.getFixtureFactory();   // registers Java module fixture builder
  final IdeaTestFixtureFactory fixtureFactory = IdeaTestFixtureFactory.getFixtureFactory();
  final TestFixtureBuilder<IdeaProjectTestFixture> testFixtureBuilder = fixtureFactory.createFixtureBuilder();
  myFixture = fixtureFactory.createTempDirTestFixture();
  myFixture.setUp();

  FileUtil.copyDir(new File(PluginPathManager.getPluginHomePath("testng") + "/testData/runConfiguration/module1"),
                   new File(myFixture.getTempDirPath()), false);

  myProjectFixture = testFixtureBuilder.getFixture();
  final JavaModuleFixtureBuilder javaModuleFixtureBuilder = testFixtureBuilder.addModule(JavaModuleFixtureBuilder.class);
  javaModuleFixtureBuilder.addContentRoot(myFixture.getTempDirPath()).addSourceRoot("src");
  javaModuleFixtureBuilder.addLibrary("testng", PathUtil.getJarPathForClass(AfterMethod.class));
  myProjectFixture.setUp();

}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:19,代码来源:ConfigurationsTest.java

示例3: tuneFixture

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@Override
protected void tuneFixture(JavaModuleFixtureBuilder moduleBuilder) throws Exception {
  moduleBuilder.addLibrary("junit3", JavaSdkUtil.getJunit3JarPath());
  moduleBuilder.addLibrary("junit4", ArrayUtil.toStringArray(JavaSdkUtil.getJUnit4JarPaths()));
  moduleBuilder.addLibrary("ideaRt", JavaSdkUtil.getIdeaRtJarPath());
  moduleBuilder.addLibrary("empty");
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:8,代码来源:JUnitDependencyScopeSuggesterTest.java

示例4: tuneFixture

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@Override
protected void tuneFixture(JavaModuleFixtureBuilder moduleBuilder) throws Exception {
  String pathForClass = PathUtil.getJarPathForClass(LocalInspectionEP.class);
  moduleBuilder.addLibrary("lang-api", pathForClass);
  String platformApiJar = PathUtil.getJarPathForClass(JBList.class);
  moduleBuilder.addLibrary("platform-api", platformApiJar);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:8,代码来源:DescriptionTypeRelatedItemLineMarkerProviderTest.java

示例5: tuneFixture

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@Override
protected void tuneFixture(JavaModuleFixtureBuilder moduleBuilder) throws Exception {
  String extensionsJar = PathUtil.getJarPathForClass(ExtensionPointName.class);
  moduleBuilder.addLibrary("extensions", extensionsJar);
  String platformApiJar = PathUtil.getJarPathForClass(JBList.class);
  moduleBuilder.addLibrary("platform-api", platformApiJar);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:8,代码来源:ExtensionPointDeclarationRelatedItemLineMarkerProviderTest.java

示例6: tuneFixture

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@Override
protected void tuneFixture(JavaModuleFixtureBuilder moduleBuilder) throws Exception {
  moduleBuilder.addLibrary("testng", PathUtil.getJarPathForClass(DataProvider.class));
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:5,代码来源:DuplicatedDataProviderNamesInspectionTest.java

示例7: tuneFixture

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@Override
protected void tuneFixture(JavaModuleFixtureBuilder moduleBuilder) throws Exception {
  moduleBuilder.setMockJdkLevel(JavaModuleFixtureBuilder.MockJdkLevel.jdk15);
  moduleBuilder.addLibrary("junit", PathUtil.getJarPathForClass(TestCase.class));
  moduleBuilder.addLibrary("testng", PathUtil.getJarPathForClass(AfterMethod.class));
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:7,代码来源:BaseTestNGInspectionsTest.java

示例8: tuneFixture

import com.intellij.testFramework.builders.JavaModuleFixtureBuilder; //导入方法依赖的package包/类
@Override
protected void tuneFixture(JavaModuleFixtureBuilder moduleBuilder) throws Exception {
  String pathForClass = PathUtil.getJarPathForClass(LocalInspectionEP.class);
  moduleBuilder.addLibrary("lang-api", pathForClass);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:6,代码来源:InspectionMappingConsistencyInspectionTest.java


注:本文中的com.intellij.testFramework.builders.JavaModuleFixtureBuilder.addLibrary方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。