private NeoStores open( FileSystemAbstraction fs, PageCache pageCache, RecordFormats format,
Function<FileSystemAbstraction,IdGeneratorFactory> idGeneratorFactory, String... config ) throws IOException
{
assert neoStores == null : "Already opened";
TestDirectory testDirectory = TestDirectory.testDirectory( fs );
testDirectory.prepareDirectory( testClass, null );
Config configuration = configOf( config );
StoreFactory storeFactory = new StoreFactory( testDirectory.databaseLayout(), configuration, idGeneratorFactory.apply( fs ),
pageCache, fs, format, NullLogProvider.getInstance(), EmptyVersionContextSupplier.EMPTY );
return neoStores = stores.length == 0
? storeFactory.openAllNeoStores( true )
: storeFactory.openNeoStores( true, stores );
}