本文整理汇总了Java中org.assertj.core.groups.Tuple类的典型用法代码示例。如果您正苦于以下问题:Java Tuple类的具体用法?Java Tuple怎么用?Java Tuple使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Tuple类属于org.assertj.core.groups包,在下文中一共展示了Tuple类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: shouldSetCorrectStatusForFailedBeforeFixtures
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Feature("Test fixtures")
@Story("Suite")
@Story("Test")
@Story("Method")
@Issue("67")
@Test(description = "Should set correct status for failed before fixtures")
public void shouldSetCorrectStatusForFailedBeforeFixtures() throws Exception {
runTestNgSuites(
"suites/failed-before-suite-fixture.xml",
"suites/failed-before-test-fixture.xml",
"suites/failed-before-method-fixture.xml"
);
assertThat(results.getTestContainers())
.flatExtracting(TestResultContainer::getBefores)
.hasSize(3)
.extracting(FixtureResult::getName, FixtureResult::getStatus)
.containsExactlyInAnyOrder(
Tuple.tuple("beforeSuite", Status.BROKEN),
Tuple.tuple("beforeTest", Status.BROKEN),
Tuple.tuple("beforeMethod", Status.BROKEN)
);
}
开发者ID:allure-framework,项目名称:allure-java,代码行数:24,代码来源:AllureTestNgTest.java
示例2: shouldSetCorrectStatusForFailedAfterFixtures
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Feature("Test fixtures")
@Story("Suite")
@Story("Test")
@Story("Method")
@Issue("67")
@Test(description = "Should set correct status for failed after fixtures")
public void shouldSetCorrectStatusForFailedAfterFixtures() throws Exception {
runTestNgSuites(
"suites/failed-after-suite-fixture.xml",
"suites/failed-after-test-fixture.xml",
"suites/failed-after-method-fixture.xml"
);
assertThat(results.getTestContainers())
.flatExtracting(TestResultContainer::getAfters)
.hasSize(3)
.extracting(FixtureResult::getName, FixtureResult::getStatus)
.containsExactlyInAnyOrder(
Tuple.tuple("afterSuite", Status.BROKEN),
Tuple.tuple("afterTest", Status.BROKEN),
Tuple.tuple("afterMethod", Status.BROKEN)
);
}
开发者ID:allure-framework,项目名称:allure-java,代码行数:24,代码来源:AllureTestNgTest.java
示例3: shouldCorrectlyCreateUserDefinedCondition
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldCorrectlyCreateUserDefinedCondition() throws Exception {
//given
when(alertsConditionsApiMock.list(POLICY.getId())).thenReturn(ImmutableList.of());
when(alertsConditionsApiMock.create(eq(POLICY.getId()), any(AlertsCondition.class))).thenReturn(AlertsCondition.builder().build());
//when
testee.sync(CONFIGURATION);
//then
verify(alertsConditionsApiMock).create(eq(POLICY.getId()), alertsConditionCaptor.capture());
AlertsCondition result = alertsConditionCaptor.getValue();
assertThat(result.getConditionScope()).isEqualTo("application");
assertThat(result.getType()).isEqualTo("apm_app_metric");
assertThat(result.getName()).isEqualTo(CONDITION_NAME);
assertThat(result.getEnabled()).isEqualTo(true);
assertThat(result.getEntities()).containsExactly(APPLICATION_ENTITY_ID);
assertThat(result.getMetric()).isEqualTo("user_defined");
assertThat(result.getTerms())
.extracting("duration", "operator", "priority", "threshold", "timeFunction")
.containsExactly(new Tuple("5", "above", "critical", "0.5", "all"));
assertThat(result.getUserDefined().getMetric()).isEqualTo(METRIC);
assertThat(result.getUserDefined().getValueFunction()).isEqualTo("average");
}
开发者ID:ocadotechnology,项目名称:newrelic-alerts-configurator,代码行数:25,代码来源:ApmUserDefinedConditionConfiguratorTest.java
示例4: shouldCorrectlyCreateUserDefinedCondition
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldCorrectlyCreateUserDefinedCondition() throws Exception {
//given
when(alertsConditionsApiMock.list(POLICY.getId())).thenReturn(ImmutableList.of());
when(alertsConditionsApiMock.create(eq(POLICY.getId()), any(AlertsCondition.class))).thenReturn(AlertsCondition.builder().build());
//when
testee.sync(CONFIGURATION);
//then
verify(alertsConditionsApiMock).create(eq(POLICY.getId()), alertsConditionCaptor.capture());
AlertsCondition result = alertsConditionCaptor.getValue();
assertThat(result.getType()).isEqualTo("apm_jvm_metric");
assertThat(result.getName()).isEqualTo(CONDITION_NAME);
assertThat(result.getEnabled()).isEqualTo(true);
assertThat(result.getEntities()).containsExactly(APPLICATION_ENTITY_ID);
assertThat(result.getMetric()).isEqualTo("gc_cpu_time");
assertThat(result.getGcMetric()).isEqualTo("GC/PS MarkSweep");
assertThat(result.getTerms())
.extracting("duration", "operator", "priority", "threshold", "timeFunction")
.containsExactly(new Tuple("5", "above", "critical", "85.0", "all"));
}
开发者ID:ocadotechnology,项目名称:newrelic-alerts-configurator,代码行数:23,代码来源:ApmJvmConditionConfiguratorTest.java
示例5: requestNotFoundMessageShouldBeLoggedForDestroyingResource
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void requestNotFoundMessageShouldBeLoggedForDestroyingResource()
throws InterruptedException, TimeoutException {
// would be better to close context but fails completing tests
filters.forEach(filter -> filter.getFilter().destroy());
ResponseEntity<String> response = restTemplate.getForEntity("/destroying", String.class);
assertThat(response.getStatusCode()).isEqualTo(HttpStatus.NOT_FOUND);
List<ILoggingEvent> events = loggedEvents();
assertThat(events).extracting("level", "message")
.containsOnlyOnce(Tuple.tuple(Level.DEBUG, "Settings logging destroyed due to timeout or filter exit"))
.containsOnlyOnce(Tuple.tuple(Level.DEBUG, "Status logging destroyed due to timeout or filter exit"));
awaitForMessage("Request GET /destroying processed");
}
开发者ID:hmcts,项目名称:java-logging,代码行数:19,代码来源:RequestLoggingComponentTest.java
示例6: should_get_creation_date_from_matched_server_issue
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void should_get_creation_date_from_matched_server_issue() {
Path moduleRoot = Paths.get("").toAbsolutePath();
String dummyFilePath = moduleRoot.resolve("dummy").toString();
Issue unmatched = mockIssue();
when(unmatched.getInputFile().getPath()).thenReturn(dummyFilePath);
Issue matched = mockIssue();
when(matched.getInputFile().getPath()).thenReturn(dummyFilePath);
Collection<Issue> issues = Arrays.asList(unmatched, matched);
ServerIssue matchedServerIssue = mockServerIssue(matched);
List<ServerIssue> serverIssues = Arrays.asList(mockServerIssue(mockIssue()), matchedServerIssue);
when(engine.getServerIssues(any(), any())).thenReturn(serverIssues);
Collection<Trackable> trackables = sonarLint.matchAndTrack(moduleRoot, issues);
assertThat(trackables).extracting("ruleKey").containsOnly(unmatched.getRuleKey(), matched.getRuleKey());
assertThat(trackables.stream().filter(t -> t.getRuleKey().equals(matched.getRuleKey())).collect(Collectors.toList()))
.extracting("ruleKey", "creationDate").containsOnly(
Tuple.tuple(matched.getRuleKey(), matchedServerIssue.creationDate().toEpochMilli())
);
}
开发者ID:SonarSource,项目名称:sonarlint-cli,代码行数:23,代码来源:ConnectedSonarLintTest.java
示例7: shouldProcessEmptyOrNullStatus
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
@SuppressWarnings("unchecked")
public void shouldProcessEmptyOrNullStatus() throws Exception {
Set<TestResult> testResults = process(
"allure1/empty-status-testsuite.xml", generateTestSuiteXmlName()
).getResults();
assertThat(testResults)
.hasSize(4)
.extracting("name", "status")
.containsExactlyInAnyOrder(
Tuple.tuple("testOne", UNKNOWN),
Tuple.tuple("testTwo", PASSED),
Tuple.tuple("testThree", FAILED),
Tuple.tuple("testFour", UNKNOWN)
);
}
开发者ID:allure-framework,项目名称:allure2,代码行数:17,代码来源:Allure1PluginTest.java
示例8: shouldProcessNullParameters
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldProcessNullParameters() throws Exception {
final Set<TestResult> results = process(
"allure1/empty-parameter-value.xml", generateTestSuiteXmlName()
).getResults();
assertThat(results)
.hasSize(1)
.flatExtracting(TestResult::getParameters)
.hasSize(4)
.extracting(Parameter::getName, Parameter::getValue)
.containsExactlyInAnyOrder(
Tuple.tuple("parameterArgument", null),
Tuple.tuple("parameter", "default"),
Tuple.tuple("invalid", null),
Tuple.tuple(null, null)
);
}
开发者ID:allure-framework,项目名称:allure2,代码行数:19,代码来源:Allure1PluginTest.java
示例9: shouldGetData
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldGetData() throws Exception {
final Configuration configuration = mock(Configuration.class);
final List<HistoryTrendItem> history = randomHistoryTrendItems();
final List<HistoryTrendItem> data = new HistoryTrendPlugin().getData(createSingleLaunchResults(
singletonMap(HISTORY_TREND_BLOCK_NAME, history),
randomTestResult().setStatus(Status.PASSED),
randomTestResult().setStatus(Status.FAILED),
randomTestResult().setStatus(Status.FAILED)
));
assertThat(data)
.hasSize(1 + history.size())
.extracting(HistoryTrendItem::getStatistic)
.extracting(Statistic::getTotal, Statistic::getFailed, Statistic::getPassed)
.first()
.isEqualTo(Tuple.tuple(3L, 2L, 1L));
final List<HistoryTrendItem> next = data.subList(1, data.size());
assertThat(next)
.containsExactlyElementsOf(history);
}
开发者ID:allure-framework,项目名称:allure2,代码行数:26,代码来源:HistoryTrendPluginTest.java
示例10: shouldCreateTest
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldCreateTest() throws Exception {
process(
"xunitdata/passed-test.xml",
"passed-test.xml"
);
final ArgumentCaptor<TestResult> captor = ArgumentCaptor.forClass(TestResult.class);
verify(visitor, times(1)).visitTestResult(captor.capture());
assertThat(captor.getAllValues())
.hasSize(1)
.extracting(TestResult::getName, TestResult::getHistoryId, TestResult::getStatus)
.containsExactlyInAnyOrder(
Tuple.tuple("passedTest", "Some test", Status.PASSED)
);
}
开发者ID:allure-framework,项目名称:allure2,代码行数:18,代码来源:XunitXmlPluginTest.java
示例11: shouldSetLabels
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldSetLabels() throws Exception {
process(
"xunitdata/passed-test.xml",
"passed-test.xml"
);
final ArgumentCaptor<TestResult> captor = ArgumentCaptor.forClass(TestResult.class);
verify(visitor, times(1)).visitTestResult(captor.capture());
assertThat(captor.getAllValues())
.hasSize(1)
.flatExtracting(TestResult::getLabels)
.extracting(Label::getName, Label::getValue)
.containsExactlyInAnyOrder(
Tuple.tuple(LabelName.SUITE.value(), "org.example.XunitTest"),
Tuple.tuple(LabelName.PACKAGE.value(), "org.example.XunitTest"),
Tuple.tuple(LabelName.TEST_CLASS.value(), "org.example.XunitTest"),
Tuple.tuple(LabelName.RESULT_FORMAT.value(), XunitXmlPlugin.XUNIT_RESULTS_FORMAT)
);
}
开发者ID:allure-framework,项目名称:allure2,代码行数:22,代码来源:XunitXmlPluginTest.java
示例12: shouldSetStatusDetails
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Theory
public void shouldSetStatusDetails(String[] inputs) throws Exception {
Assume.assumeTrue(inputs.length == 4);
process(
inputs[0],
inputs[1]
);
final ArgumentCaptor<TestResult> captor = ArgumentCaptor.forClass(TestResult.class);
verify(visitor, times(1)).visitTestResult(captor.capture());
assertThat(captor.getAllValues())
.hasSize(1)
.extracting(TestResult::getStatusMessage, TestResult::getStatusTrace)
.containsExactlyInAnyOrder(
Tuple.tuple(inputs[2], inputs[3])
);
}
开发者ID:allure-framework,项目名称:allure2,代码行数:19,代码来源:XunitXmlPluginTest.java
示例13: shouldAddLabels
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldAddLabels() throws Exception {
process(
"junitdata/TEST-test.SampleTest.xml", "TEST-test.SampleTest.xml"
);
final ArgumentCaptor<TestResult> captor = ArgumentCaptor.forClass(TestResult.class);
verify(visitor, times(1)).visitTestResult(captor.capture());
assertThat(captor.getAllValues())
.hasSize(1)
.flatExtracting(TestResult::getLabels)
.extracting(Label::getName, Label::getValue)
.containsExactlyInAnyOrder(
Tuple.tuple(LabelName.SUITE.value(), "test.SampleTest"),
Tuple.tuple(LabelName.PACKAGE.value(), "test.SampleTest"),
Tuple.tuple(LabelName.TEST_CLASS.value(), "test.SampleTest"),
Tuple.tuple(LabelName.RESULT_FORMAT.value(), JunitXmlPlugin.JUNIT_RESULTS_FORMAT)
);
}
开发者ID:allure-framework,项目名称:allure2,代码行数:21,代码来源:JunitXmlPluginTest.java
示例14: testCursorAndAuthorization
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void testCursorAndAuthorization() throws Exception {
final String headerName = "X-Nakadi-Cursors";
final String headerValue = "[{\"partition\": \"0\", \"offset\":\"BEGIN\"}]";
final String authorization = "Bearer b09bb129-3820-4178-af1e-1158a5464b56";
final String body = "TEST";
when(mockRequestProducer.getHeaders()).thenReturn(Collections.singletonMap(headerName, headerValue));
rxHttpRequest = new RxHttpRequest(TimeUnit.MINUTES.toMillis(10), () -> authorization);
stubFor(get(urlEqualTo(EVENTS_RESOURCE)).withHeader("Authorization", equalTo(authorization)).withHeader(
headerName, equalTo(headerValue)).willReturn(aResponse().withStatus(200).withBody(body)));
final Observable<HttpResponseChunk> observable = rxHttpRequest.createRequest(mockRequestProducer);
final TestSubscriber<HttpResponseChunk> testSubscriber = new TestSubscriber<>();
observable.subscribe(testSubscriber);
testSubscriber.assertNoErrors();
final List<HttpResponseChunk> chunks = testSubscriber.getOnNextEvents();
assertThat(chunks).hasSize(1);
assertThat(chunks).extracting("statusCode", "content").containsOnly(Tuple.tuple(200, body));
WireMock.verify(1, getRequestedFor(urlEqualTo(EVENTS_RESOURCE)));
}
开发者ID:zalando-nakadi,项目名称:paradox-nakadi-consumer,代码行数:25,代码来源:RxHttpRequestTest.java
示例15: testTwoEvents
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void testTwoEvents() {
handler.onResponse(TWO_EVENTS);
final ArgumentCaptor<EventTypeCursor> eventCursorCaptor = ArgumentCaptor.forClass(EventTypeCursor.class);
final ArgumentCaptor<OrderReceived> orderReceivedCaptor = ArgumentCaptor.forClass(OrderReceived.class);
verify(delegate, times(2)).onEvent(eventCursorCaptor.capture(), orderReceivedCaptor.capture());
assertThat(orderReceivedCaptor.getAllValues()).extracting("orderNumber").containsExactly("24873243241",
"24873243242");
final ArgumentCaptor<EventTypeCursor> coordinatorCursorCaptor = ArgumentCaptor.forClass(EventTypeCursor.class);
verify(coordinator, times(1)).commit(coordinatorCursorCaptor.capture());
assertThat(coordinatorCursorCaptor.getAllValues()).extracting("eventTypePartition", "offset").containsExactly(
Tuple.tuple(EVENT_TYPE_PARTITION, "9"));
}
开发者ID:zalando-nakadi,项目名称:paradox-nakadi-consumer,代码行数:18,代码来源:BatchEventsResponseHandlerTest.java
示例16: testThreeEvents
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void testThreeEvents() {
handler.onResponse(THREE_EVENTS);
final ArgumentCaptor<EventTypeCursor> eventCursorCaptor = ArgumentCaptor.forClass(EventTypeCursor.class);
final ArgumentCaptor<OrderReceived> orderReceivedCaptor = ArgumentCaptor.forClass(OrderReceived.class);
verify(delegate, times(3)).onEvent(eventCursorCaptor.capture(), orderReceivedCaptor.capture());
assertThat(orderReceivedCaptor.getAllValues()).extracting("orderNumber").containsExactly("24873243241",
"24873243242", "24873243243");
final ArgumentCaptor<EventTypeCursor> coordinatorCursorCaptor = ArgumentCaptor.forClass(EventTypeCursor.class);
verify(coordinator, times(1)).commit(coordinatorCursorCaptor.capture());
assertThat(coordinatorCursorCaptor.getAllValues()).extracting("eventTypePartition", "offset").containsExactly(
Tuple.tuple(EVENT_TYPE_PARTITION, "9"));
}
开发者ID:zalando-nakadi,项目名称:paradox-nakadi-consumer,代码行数:18,代码来源:BatchEventsResponseHandlerTest.java
示例17: testTwoEvents
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void testTwoEvents() {
handler.onResponse(TWO_EVENTS);
final ArgumentCaptor<EventTypeCursor> eventCursorCaptor = ArgumentCaptor.forClass(EventTypeCursor.class);
final ArgumentCaptor<String> rawEventCaptor = ArgumentCaptor.forClass(String.class);
verify(delegate, times(2)).onEvent(eventCursorCaptor.capture(), rawEventCaptor.capture());
assertThat(rawEventCaptor.getAllValues().get(0)).isEqualTo(TWO_EVENTS_1);
assertThat(rawEventCaptor.getAllValues().get(1)).isEqualTo(TWO_EVENTS_2);
final ArgumentCaptor<EventTypeCursor> coordinatorCursorCaptor = ArgumentCaptor.forClass(EventTypeCursor.class);
verify(coordinator, times(1)).commit(coordinatorCursorCaptor.capture());
assertThat(coordinatorCursorCaptor.getAllValues()).extracting("eventTypePartition", "offset").containsExactly(
Tuple.tuple(EVENT_TYPE_PARTITION, "9"));
}
开发者ID:zalando-nakadi,项目名称:paradox-nakadi-consumer,代码行数:18,代码来源:RawEventResponseHandlerTest.java
示例18: shouldReturnBuildOrder
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
@Test
public void shouldReturnBuildOrder() {
Worker worker = produceWorker(Worker.Status.READY);
Build build = produceBuild();
JobBuild jobBuild = produceJobBuild(worker, build, JobBuild.Status.READY);
BuildOrder buildOrder = jobBuildService.peekBuildFor("testingWorker").get();
assertThat(buildOrder).isNotNull();
assertThat(buildOrder.getBuildId()).isEqualTo(jobBuild.getId());
assertThat(buildOrder.getCommands()).containsExactly("echo bar");
assertThat(buildOrder.getDockerImage()).isEqualTo("centos");
assertThat(buildOrder.getEnvironment()).extracting("name", "value")
.contains(Tuple.tuple("FOO", "bar"));
Optional<BuildOrder> optional = jobBuildService.peekBuildFor("testingWorker");
assertThat(optional.isPresent()).isFalse();
}
开发者ID:dick-the-deployer,项目名称:dick,代码行数:20,代码来源:JobBuildServiceTest.java
示例19: validateSuccessfulIngest
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
private void validateSuccessfulIngest(JobScenario.IngestJobInfo ingestJobInfo, Asset asset, Variant variant, Job ingestJob, Repository repository) {
// validate job
ingestJob = jobManager.getJob(ingestJob.getId()).get();
assertThat(ingestJob.getStatus()).isEqualTo(JobStatus.COMPLETED);
// validate variant repository
List<VariantRepository> variantRepositories = contentManager.findVariantRepositories(asset.getId(), variant.getId(), new DefaultSearchBuilder().build()).getRecords();
assertThat(variantRepositories).hasSize(1).extracting("repositoryName", "type").contains(new Tuple(repository.getRepositoryName(), repository.getType()));
// validate variant files
List<VariantFile> variantFiles =
contentManager.findVariantFiles(variant.getId(), new VariantFileSearchBuilder().orderBy(VariantFile.ORIGINAL_FILENAME).sortOrder(SortOrder.ASC).build()).getRecords();
IntStream.range(0, ingestJobInfo.getNumberOfFiles()).forEach(i -> {
String originalFileName = "test-file" + i + ".txt";
assertThat(variantFiles.get(i)).isEqualToComparingOnlyGivenFields(new VariantFile(originalFileName, 1024L, originalFileName, "", null), "size", "originalFilename");
assertThat(variantFiles.get(i).getHashes()).hasSize(1).extracting("hash", "hashAlgorithm").containsExactly(new Tuple("abc-def", "MD5"));
});
// validate repository files
IntStream.range(0, ingestJobInfo.getNumberOfFiles()).forEach(i -> {
RepositoryFile expectedRepositoryFile = new RepositoryFile(null, variant.getId(), variantFiles.get(i).getId());
Assertions.assertThat(repositoryManager.getRepositoryFilesForVariant(repository.getId(), variant.getId())).hasSize(ingestJobInfo.getNumberOfFiles())
.usingElementComparatorOnFields("variantId", "variantFileId").contains(expectedRepositoryFile);
});
}
开发者ID:projectomakase,项目名称:omakase,代码行数:26,代码来源:IngestDelegate.java
示例20: validateFailedReplication
import org.assertj.core.groups.Tuple; //导入依赖的package包/类
private void validateFailedReplication(Asset asset, Variant variant, Job replicationJob, Repository sourceRepository, Repository destinationRepository, int numberOfFiles) {
// validate job
replicationJob = jobManager.getJob(replicationJob.getId()).get();
assertThat(replicationJob.getStatus()).isEqualTo(JobStatus.FAILED);
// validate variant repository
List<VariantRepository> variantRepositories =
contentManager.findVariantRepositories(asset.getId(), variant.getId(), new VariantRepositorySearchBuilder().orderBy(VariantRepository.CREATED).sortOrder(SortOrder.ASC).build())
.getRecords();
assertThat(variantRepositories).hasSize(1).extracting("repositoryName", "type").contains(new Tuple(sourceRepository.getRepositoryName(), sourceRepository.getType()));
// validate variant files
List<VariantFile> variantFiles =
contentManager.findVariantFiles(variant.getId(), new VariantFileSearchBuilder().orderBy(VariantFile.ORIGINAL_FILENAME).sortOrder(SortOrder.ASC).build()).getRecords();
IntStream.range(0, numberOfFiles).forEach(i -> {
String originalFileName = "test-file" + i + ".txt";
assertThat(variantFiles.get(i)).isEqualToComparingOnlyGivenFields(new VariantFile(originalFileName, 1024L, originalFileName, "", null), "size", "originalFilename");
Assertions.assertThat(variantFiles.get(i).getHashes()).hasSize(1).extracting("hash", "hashAlgorithm").containsExactly(new Tuple("abc-def", "MD5"));
});
// validate repository files
assertThat(repositoryManager.getRepositoryFilesForVariant(destinationRepository.getId(), variant.getId())).isEmpty();
}
开发者ID:projectomakase,项目名称:omakase,代码行数:24,代码来源:ReplicationDelegate.java
注:本文中的org.assertj.core.groups.Tuple类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论