use of com.orientechnologies.orient.core.index.OIndexManager in project orientdb by orientechnologies.
the class IndexManagerTest method testGetClassInvolvedIndexesOnePropertyBrokenClassNameCase.
@Test(dependsOnMethods = { "createCompositeIndexTestWithListener", "createCompositeIndexTestWithoutListener", "testCreateOnePropertyIndexTest" })
public void testGetClassInvolvedIndexesOnePropertyBrokenClassNameCase() {
final OIndexManager indexManager = database.getMetadata().getIndexManager();
final Set<OIndex<?>> result = indexManager.getClassInvolvedIndexes("ClaSSforindeXmanagerTEST", Arrays.asList("fOne"));
assertEquals(result.size(), 3);
assertTrue(containsIndex(result, "propertyone"));
assertTrue(containsIndex(result, "compositeone"));
assertTrue(containsIndex(result, "compositetwo"));
}
use of com.orientechnologies.orient.core.index.OIndexManager in project orientdb by orientechnologies.
the class IndexManagerTest method testGetClassInvolvedIndexesPropertiesMorThanNeededArrayParams.
@Test(dependsOnMethods = { "createCompositeIndexTestWithListener", "createCompositeIndexTestWithoutListener", "testCreateOnePropertyIndexTest" })
public void testGetClassInvolvedIndexesPropertiesMorThanNeededArrayParams() {
final OIndexManager indexManager = database.getMetadata().getIndexManager();
final Set<OIndex<?>> result = indexManager.getClassInvolvedIndexes(CLASS_NAME, "fTwo", "fOne", "fThee", "fFour");
assertEquals(result.size(), 0);
}
use of com.orientechnologies.orient.core.index.OIndexManager in project orientdb by orientechnologies.
the class IndexManagerTest method testGetClassIndexWrongClassName.
@Test(dependsOnMethods = { "createCompositeIndexTestWithListener", "createCompositeIndexTestWithoutListener", "testCreateOnePropertyIndexTest" })
public void testGetClassIndexWrongClassName() {
final OIndexManager indexManager = database.getMetadata().getIndexManager();
final OIndex<?> result = indexManager.getClassIndex("testClassTT", "propertyone");
assertNull(result);
}
use of com.orientechnologies.orient.core.index.OIndexManager in project orientdb by orientechnologies.
the class IndexManagerTest method testAreIndexedThreePropertiesArrayParams.
@Test(dependsOnMethods = { "createCompositeIndexTestWithListener", "createCompositeIndexTestWithoutListener", "testCreateOnePropertyIndexTest" })
public void testAreIndexedThreePropertiesArrayParams() {
final OIndexManager indexManager = database.getMetadata().getIndexManager();
final boolean result = indexManager.areIndexed(CLASS_NAME, "fTwo", "fOne", "fThree");
assertTrue(result);
}
use of com.orientechnologies.orient.core.index.OIndexManager in project orientdb by orientechnologies.
the class IndexManagerTest method testGetClassInvolvedIndexesNotInvolvedProperties.
@Test(dependsOnMethods = { "createCompositeIndexTestWithListener", "createCompositeIndexTestWithoutListener", "testCreateOnePropertyIndexTest" })
public void testGetClassInvolvedIndexesNotInvolvedProperties() {
final OIndexManager indexManager = database.getMetadata().getIndexManager();
final Set<OIndex<?>> result = indexManager.getClassInvolvedIndexes(CLASS_NAME, Arrays.asList("fTwo", "fFour"));
assertEquals(result.size(), 0);
}
Aggregations