use of org.junit.jupiter.params.provider.EnumSource in project harvest-client by 3AP-AG.
the class ProjectsApiCreateTest method createDefaultBilling.
@ParameterizedTest
@EnumSource(Project.BillingMethod.class)
void createDefaultBilling(Project.BillingMethod billingMethod, TestInfo testInfo) {
Reference<Client> clientReference = ExistingData.getInstance().getClientReference();
String name = "Project for test " + testInfo.getDisplayName();
boolean billable = true;
Project.BudgetMethod budgetBy = Project.BudgetMethod.HOURS_PER_PROJECT;
Project creationInfo = ImmutableProject.builder().client(clientReference).name(name).billable(billable).billBy(billingMethod).budgetBy(budgetBy).build();
project = projectsApi.create(creationInfo);
assertThat(project.getBillable()).isEqualTo(billable);
assertThat(project.getBillBy()).isEqualTo(billingMethod);
assertThat(project.getBudgetBy()).isEqualTo(budgetBy);
assertThat(project.getName()).isEqualTo(name);
assertThat(project.getClient().getId()).isEqualTo(clientReference.getId());
}
use of org.junit.jupiter.params.provider.EnumSource in project qpp-conversion-tool by CMSgov.
the class TemplateIdTest method testInvalidExtensionFindWithNoExtensionEnforcement.
@ParameterizedTest
@EnumSource(value = TemplateId.class, mode = EXCLUDE, names = { "CLINICAL_DOCUMENT" })
void testInvalidExtensionFindWithNoExtensionEnforcement(TemplateId templateId) {
TemplateId actual = TemplateId.getTemplateId(templateId.getRoot(), "nonExistingExtension", new Context());
assertThat(actual).isSameAs(templateId);
}
Aggregations