Search in sources :

Example 1 with UnknownTypeRule

use of au.gov.asd.tac.constellation.views.qualitycontrol.rules.UnknownTypeRule in project constellation by constellation-app.

the class QualityControlViewPaneNGTest method testGetPriorities.

/**
 * Test of getPriorities method, of class QualityControlViewPane.
 */
@Test
public void testGetPriorities() {
    System.out.println("getPriorities");
    final Map<QualityControlRule, QualityCategory> result = QualityControlViewPane.getPriorities();
    assertEquals(result.size(), rules.size());
    for (final QualityControlRule rule : result.keySet()) {
        rule.clearResults();
    }
    final IdentifierInconsistentWithTypeRule iiRule = new IdentifierInconsistentWithTypeRule();
    final MissingTypeRule mRule = new MissingTypeRule();
    final UnknownTypeRule uRule = new UnknownTypeRule();
    assertEquals(result.get(iiRule), QualityCategory.MEDIUM);
    assertEquals(result.get(mRule), QualityCategory.SEVERE);
    assertEquals(result.get(uRule), QualityCategory.MINOR);
}
Also used : QualityControlRule(au.gov.asd.tac.constellation.views.qualitycontrol.rules.QualityControlRule) MissingTypeRule(au.gov.asd.tac.constellation.views.qualitycontrol.rules.MissingTypeRule) QualityCategory(au.gov.asd.tac.constellation.views.qualitycontrol.QualityControlEvent.QualityCategory) IdentifierInconsistentWithTypeRule(au.gov.asd.tac.constellation.views.qualitycontrol.rules.IdentifierInconsistentWithTypeRule) UnknownTypeRule(au.gov.asd.tac.constellation.views.qualitycontrol.rules.UnknownTypeRule) Test(org.testng.annotations.Test)

Aggregations

QualityCategory (au.gov.asd.tac.constellation.views.qualitycontrol.QualityControlEvent.QualityCategory)1 IdentifierInconsistentWithTypeRule (au.gov.asd.tac.constellation.views.qualitycontrol.rules.IdentifierInconsistentWithTypeRule)1 MissingTypeRule (au.gov.asd.tac.constellation.views.qualitycontrol.rules.MissingTypeRule)1 QualityControlRule (au.gov.asd.tac.constellation.views.qualitycontrol.rules.QualityControlRule)1 UnknownTypeRule (au.gov.asd.tac.constellation.views.qualitycontrol.rules.UnknownTypeRule)1 Test (org.testng.annotations.Test)1