//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void labelScanStoreIsDirtyWhenIndexIsNotClean() throws java.io.IOException //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void LabelScanStoreIsDirtyWhenIndexIsNotClean() { PageCache pageCache = _pageCacheRule.getPageCache(_fileSystemRule.get()); CreateDirtyIndex(pageCache); Monitors monitors = new Monitors(); RecordingMonitor monitor = new RecordingMonitor(); monitors.AddMonitorListener(monitor); NativeLabelScanStore nativeLabelScanStore = new NativeLabelScanStore(pageCache, _testDirectory.databaseLayout(), _fileSystemRule.get(), EMPTY, true, monitors, ignore()); nativeLabelScanStore.Init(); nativeLabelScanStore.Start(); assertTrue(nativeLabelScanStore.Dirty); nativeLabelScanStore.Shutdown(); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void doNotRebuildIfOpenedInReadOnlyModeAndIndexIsNotClean() throws java.io.IOException //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void DoNotRebuildIfOpenedInReadOnlyModeAndIndexIsNotClean() { PageCache pageCache = _pageCacheRule.getPageCache(_fileSystemRule.get()); CreateDirtyIndex(pageCache); Monitors monitors = new Monitors(); RecordingMonitor monitor = new RecordingMonitor(); monitors.AddMonitorListener(monitor); NativeLabelScanStore nativeLabelScanStore = new NativeLabelScanStore(pageCache, _testDirectory.databaseLayout(), _fileSystemRule.get(), EMPTY, true, monitors, ignore()); nativeLabelScanStore.Init(); nativeLabelScanStore.Start(); assertTrue(monitor.NotValid); assertFalse(monitor.RebuiltConflict); assertFalse(monitor.RebuildingConflict); nativeLabelScanStore.Shutdown(); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void mustBeDirtyIfFailedDuringRebuild() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void MustBeDirtyIfFailedDuringRebuild() { // given PageCache pageCache = _pageCacheRule.getPageCache(_fileSystemRule.get()); CreateDirtyIndex(pageCache); // when RecordingMonitor monitor = new RecordingMonitor(); Monitors monitors = new Monitors(); monitors.AddMonitorListener(monitor); NativeLabelScanStore nativeLabelScanStore = new NativeLabelScanStore(pageCache, _testDirectory.databaseLayout(), _fileSystemRule.get(), EMPTY, false, monitors, immediate()); nativeLabelScanStore.Init(); nativeLabelScanStore.Start(); // then assertTrue(monitor.NotValid); assertTrue(monitor.RebuildingConflict); assertTrue(monitor.RebuiltConflict); nativeLabelScanStore.Shutdown(); }