use of org.neo4j.kernel.impl.coreapi.PlaceboTransaction in project neo4j by neo4j.
the class TestPlaceboTransaction method before.
@Before
public void before() throws Exception {
ThreadToStatementContextBridge bridge = mock(ThreadToStatementContextBridge.class);
when(bridge.get()).thenReturn(mock(Statement.class));
kernelTransaction = spy(KernelTransaction.class);
Statement statement = mock(Statement.class);
readOps = mock(ReadOperations.class);
when(statement.readOperations()).thenReturn(readOps);
when(bridge.get()).thenReturn(statement);
placeboTx = new PlaceboTransaction(() -> kernelTransaction, bridge);
resource = mock(Node.class);
when(resource.getId()).thenReturn(1L);
}
Aggregations