//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test @SuppressWarnings("unchecked") public void shouldOnlySummarizeStatisticsWhenAllReferencesAreChecked() public virtual void ShouldOnlySummarizeStatisticsWhenAllReferencesAreChecked() { // given ConsistencySummaryStatistics summary = mock(typeof(ConsistencySummaryStatistics)); RecordAccess records = mock(typeof(RecordAccess)); ConsistencyReporter.ReportHandler handler = new ConsistencyReporter.ReportHandler(new InconsistencyReport(mock(typeof(InconsistencyLogger)), summary), mock(typeof(ConsistencyReporter.ProxyFactory)), RecordType.PROPERTY, records, new PropertyRecord(0), NO_MONITOR); RecordReference <PropertyRecord> reference = mock(typeof(RecordReference)); ComparativeRecordChecker <PropertyRecord, PropertyRecord, ConsistencyReport_PropertyConsistencyReport> checker = mock(typeof(ComparativeRecordChecker)); handler.comparativeCheck(reference, checker); ArgumentCaptor <PendingReferenceCheck <PropertyRecord> > captor = ( ArgumentCaptor )ArgumentCaptor.forClass(typeof(PendingReferenceCheck)); verify(reference).dispatch(captor.capture()); PendingReferenceCheck pendingRefCheck = captor.Value; // when handler.updateSummary(); // then verifyZeroInteractions(summary); // when pendingRefCheck.skip(); // then verify(summary).update(RecordType.PROPERTY, 0, 0); verifyNoMoreInteractions(summary); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void shouldSummarizeStatisticsAfterCheck() public virtual void ShouldSummarizeStatisticsAfterCheck() { // given ConsistencySummaryStatistics summary = mock(typeof(ConsistencySummaryStatistics)); //JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @SuppressWarnings("unchecked") org.neo4j.consistency.store.RecordAccess records = mock(org.neo4j.consistency.store.RecordAccess.class); RecordAccess records = mock(typeof(RecordAccess)); ConsistencyReporter.ReportHandler handler = new ConsistencyReporter.ReportHandler(new InconsistencyReport(mock(typeof(InconsistencyLogger)), summary), mock(typeof(ConsistencyReporter.ProxyFactory)), RecordType.PROPERTY, records, new PropertyRecord(0), NO_MONITOR); // when handler.updateSummary(); // then verify(summary).update(RecordType.PROPERTY, 0, 0); verifyNoMoreInteractions(summary); }