private static void AssertDoesNotKnowAboutRelGroups(CommandReader reader) { try { reader.Read(ChannelWithRelGroupRecord()); fail("Exception expected"); } catch (IOException e) { assertEquals("Unknown command type[" + NeoCommandType_Fields.RelGroupCommand + "]", e.Message); } }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void shouldWriteIndexDefineCommandIfMapWithinShortRange() throws java.io.IOException //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void ShouldWriteIndexDefineCommandIfMapWithinShortRange() { // GIVEN InMemoryClosableChannel channel = new InMemoryClosableChannel(10_000); IndexDefineCommand command = InitIndexDefineCommand(300); // WHEN command.Serialize(channel); // THEN CommandReader commandReader = (new RecordStorageCommandReaderFactory()).byVersion(LogEntryVersion.CURRENT.byteCode()); IndexDefineCommand read = ( IndexDefineCommand )commandReader.Read(channel); assertEquals(command.IndexNameIdRange, read.IndexNameIdRange); assertEquals(command.KeyIdRange, read.KeyIdRange); }
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: //ORIGINAL LINE: private void assertCanReadRelGroup(org.neo4j.storageengine.api.CommandReader reader) throws java.io.IOException private void AssertCanReadRelGroup(CommandReader reader) { StorageCommand command = reader.Read(ChannelWithRelGroupRecord()); AssertValidRelGroupCommand(command); }