use of org.neo4j.bolt.runtime.statemachine.TransactionStateMachineSPI in project neo4j by neo4j.
the class TransactionStateMachineSPIProviderV4Test method shouldReturnDefaultTransactionStateMachineSPIWithEmptyDatabasename.
@Test
void shouldReturnDefaultTransactionStateMachineSPIWithEmptyDatabasename() throws Throwable {
String databaseName = "neo4j";
DatabaseManagementService managementService = managementService(databaseName);
TransactionStateMachineSPIProvider spiProvider = newSpiProvider(managementService);
when(mockBoltChannel.defaultDatabase()).thenReturn("neo4j");
TransactionStateMachineSPI spi = spiProvider.getTransactionStateMachineSPI("", mock(StatementProcessorReleaseManager.class, RETURNS_MOCKS));
assertThat(spi).isInstanceOf(TransactionStateMachineV4SPI.class);
}
Aggregations