src/test/java/org/thegalactic/context/constraint/categorical/CategoricalAttributeTest.java
@Test
    public void testIndexOf() {
        CategoricalAttribute attribute = CategoricalModel.create().addAttribute();
        assertEquals(0, attribute.indexOf(attribute.addValue("Test1")));
        assertEquals(1, attribute.indexOf(attribute.addValue("Test2")));
        assertEquals(2, attribute.indexOf(attribute.addValue("Test3")));
    }
/**
     * Test of indexOf method, of class CategoricalAttribute.
     */
Test of indexOf method, of class CategoricalAttribute.
Test of indexOf method of class CategoricalAttribute .
@Test
    public void testIndexOf() {
        CategoricalAttribute attribute = CategoricalModel.create().addAttribute();
        assertEquals(0, attribute.indexOf(attribute.addValue("Test1")));
        assertEquals(1, attribute.indexOf(attribute.addValue("Test2")));
        assertEquals(2, attribute.indexOf(attribute.addValue("Test3")));
    }
@ Test public void testIndexOf ( ) { CategoricalAttribute attribute = CategoricalModel . create ( ) . addAttribute ( ) ; assertEquals ( 0 , attribute . indexOf ( attribute . addValue ( "Test1" ) ) ) ; assertEquals ( 1 , attribute . indexOf ( attribute . addValue ( "Test2" ) ) ) ; assertEquals ( 2 , attribute . indexOf ( attribute . addValue ( "Test3" ) ) ) ; }
Test of indexOf method, of class CategoricalAttribute.
Test of indexOf method of class CategoricalAttribute .