org.gradle.api.tasks.testing.Test.systemProperty()方法的使用及代码示例

x33g5p2x  于2022-01-30 转载在 其他  
字(2.8k)|赞(0)|评价(0)|浏览(158)

本文整理了Java中org.gradle.api.tasks.testing.Test.systemProperty()方法的一些代码示例,展示了Test.systemProperty()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Test.systemProperty()方法的具体详情如下:
包路径:org.gradle.api.tasks.testing.Test
类名称:Test
方法名:systemProperty

Test.systemProperty介绍

暂无

代码示例

代码示例来源:origin: blox/blox

@Option(option = "aws-region", description = "AWS region to use for test", order = 1)
public void setRegion(String region) {
 super.systemProperty(AWS_REGION, region);
}

代码示例来源:origin: blox/blox

@Option(option = "aws-profile", description = "AWS credential profile to use for test", order = 2)
public void setProfile(String profile) {
 super.systemProperty(AWS_PROFILE, profile);
}

代码示例来源:origin: blox/blox

@Option(option = "endpoint", description = "Blox service endpoint", order = 3)
public void setEndpoint(String endpoint) {
 super.systemProperty(BLOX_ENDPOINT, endpoint);
}

代码示例来源:origin: com.tngtech.jgiven/jgiven-gradle-plugin

@Override
  public void execute( Task task ) {
    Test test = (Test) task;
    test.systemProperty( Config.JGIVEN_REPORT_DIR, extension.getResultsDir().getAbsolutePath() );
  }
} );

代码示例来源:origin: gradle.plugin.com.intershop.gradle.plugin.azure/azurePlugin

@Override
  void configure(Task task)
  {
    super.configure(task);

    Task prepareMonitorEnvTask = project.getTasks().findByName(AzurePlugin.PREPARE_MONITOR_ENV_TASK);

    Test t = (Test)task;

    t.setDescription("Test execution of the azureTest source set against production deployment.");

    t.dependsOn(prepareMonitorEnvTask);

    t.setClasspath(sourceSet.getRuntimeClasspath());
    t.setTestClassesDirs(sourceSet.getOutput().getClassesDirs());

    t.systemProperty("testEnvPath", azure.getMonitorEnvFile().get().getAsFile().getAbsolutePath());

    t.setBinResultsDir(new File(project.getBuildDir(), "monitor-test-results/binary/test"));

    t.getReports().getHtml().setDestination(new File(project.getBuildDir(), "reports/monitor-test-results" ));
    t.getReports().getJunitXml().setDestination(new File(project.getBuildDir(), "monitor-test-results" ));
  }
}

代码示例来源:origin: gradle.plugin.com.intershop.gradle.plugin.azure/azurePlugin

@Override
  void configure(Task task)
  {
    super.configure(task);

    Task prepareTestEnvTask = project.getTasks().findByName(AzurePlugin.PREPARE_TEST_ENV_TASK);

    Task cleanupTestEnvTask = project.getTasks().findByName(AzurePlugin.CLEANUP_TEST_ENV_TASK);

    Task triggerTestCleanUpTask = project.getTasks().findByName(AzurePlugin.TRIGGER_CLEAN_TEST_ENV);

    Test t = (Test)task;

    t.setDescription("Test execution of the azureTest source set.");

    t.dependsOn(prepareTestEnvTask, triggerTestCleanUpTask);

    t.finalizedBy(cleanupTestEnvTask);

    t.setClasspath(sourceSet.getRuntimeClasspath());
    t.setTestClassesDirs(sourceSet.getOutput().getClassesDirs());

    t.systemProperty("testEnvPath", azure.getTestEnvFile().get().getAsFile().getAbsolutePath());

  }
}

相关文章