//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void txReturnsCorrectIdWhenRolledBack() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void TxReturnsCorrectIdWhenRolledBack() { ExecuteDummyTxs(Db, 42); [email protected] tx = NewTransaction(AUTH_DISABLED); tx.DataWrite().nodeCreate(); tx.Failure(); assertEquals(KernelTransaction.ROLLBACK, tx.CloseTransaction()); assertFalse(tx.Open); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void txReturnsCorrectIdWhenMarkedForTermination() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void TxReturnsCorrectIdWhenMarkedForTermination() { ExecuteDummyTxs(Db, 42); [email protected] tx = NewTransaction(AUTH_DISABLED); tx.DataWrite().nodeCreate(); tx.MarkForTermination(Org.Neo4j.Kernel.Api.Exceptions.Status_Transaction.Terminated); assertEquals(KernelTransaction.ROLLBACK, tx.CloseTransaction()); assertFalse(tx.Open); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void txReturnsCorrectIdWhenCommitted() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void TxReturnsCorrectIdWhenCommitted() { ExecuteDummyTxs(Db, 42); [email protected] tx = NewTransaction(AUTH_DISABLED); tx.DataWrite().nodeCreate(); tx.Success(); long previousCommittedTxId = LastCommittedTxId(Db); assertEquals(previousCommittedTxId + 1, tx.CloseTransaction()); assertFalse(tx.Open); }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @Test public void txReturnsCorrectIdWhenReadOnly() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#: public virtual void TxReturnsCorrectIdWhenReadOnly() { ExecuteDummyTxs(Db, 42); [email protected] tx = NewTransaction(); using (NodeCursor node = tx.Cursors().allocateNodeCursor()) { tx.DataRead().singleNode(1, node); node.Next(); } tx.Success(); assertEquals(KernelTransaction.READ_ONLY, tx.CloseTransaction()); assertFalse(tx.Open); }