}
private void verifyUsesInfinispanDirectory(NRTIndexManager nrti, int expectedChunkSize, EmbeddedCacheManager embeddedCacheManager) throws IllegalArgumentException, IllegalAccessException, SecurityException, NoSuchFieldException {
DirectoryProvider directoryProvider = nrti.getDirectoryProvider();
Assert.assertTrue(directoryProvider instanceof InfinispanDirectoryProvider);
InfinispanDirectoryProvider ispn = (InfinispanDirectoryProvider)directoryProvider;
Directory infinispanDirectory = ispn.getDirectory();
DirectoryExtensions extended = (DirectoryExtensions)infinispanDirectory;
Assert.assertEquals(expectedChunkSize, extended.getChunkSize());
Assert.assertEquals(extended.getMetadataCache().getName(), "LuceneIndexesMetadataOWR");