src/test/java/org/thegalactic/lattice/ConceptLatticeTest.java
@Test
    public void testDiagramLattice() {
        TreeSet<Comparable> comparablesAtts = new TreeSet<Comparable>();
        TreeSet<Comparable> comparablesObjs = new TreeSet<Comparable>();
        comparablesAtts.add((Comparable) "a");
        comparablesAtts.add((Comparable) "b");
        comparablesAtts.add((Comparable) "c");
        comparablesObjs.add((Comparable) "1");
        comparablesObjs.add((Comparable) "2");
        comparablesObjs.add((Comparable) "3");
        Context cs = new Context();
        cs.addAllToAttributes(comparablesAtts);
        cs.addAllToObservations(comparablesObjs);
        cs.addExtentIntent("1", "a");
        cs.addExtentIntent("2", "a");
        cs.addExtentIntent("3", "b");
        cs.addExtentIntent("3", "c");
        ConceptLattice result = ConceptLattice.diagramLattice(cs);
        assertEquals(null, ((Node) result.getNodes().first()).getContent());
    }
/**
     * Test of diagramLattice method, of class ConceptLattice.
     */
Test of diagramLattice method, of class ConceptLattice.
Test of diagramLattice method of class ConceptLattice .
@Test
    public void testDiagramLattice() {
        TreeSet<Comparable> comparablesAtts = new TreeSet<Comparable>();
        TreeSet<Comparable> comparablesObjs = new TreeSet<Comparable>();
        comparablesAtts.add((Comparable) "a");
        comparablesAtts.add((Comparable) "b");
        comparablesAtts.add((Comparable) "c");
        comparablesObjs.add((Comparable) "1");
        comparablesObjs.add((Comparable) "2");
        comparablesObjs.add((Comparable) "3");
        Context cs = new Context();
        cs.addAllToAttributes(comparablesAtts);
        cs.addAllToObservations(comparablesObjs);
        cs.addExtentIntent("1", "a");
        cs.addExtentIntent("2", "a");
        cs.addExtentIntent("3", "b");
        cs.addExtentIntent("3", "c");
        ConceptLattice result = ConceptLattice.diagramLattice(cs);
        assertEquals(null, ((Node) result.getNodes().first()).getContent());
    }
@ Test public void testDiagramLattice ( ) { TreeSet < Comparable > comparablesAtts = new TreeSet < Comparable > ( ) ; TreeSet < Comparable > comparablesObjs = new TreeSet < Comparable > ( ) ; comparablesAtts . add ( ( Comparable ) "a" ) ; comparablesAtts . add ( ( Comparable ) "b" ) ; comparablesAtts . add ( ( Comparable ) "c" ) ; comparablesObjs . add ( ( Comparable ) "1" ) ; comparablesObjs . add ( ( Comparable ) "2" ) ; comparablesObjs . add ( ( Comparable ) "3" ) ; Context cs = new Context ( ) ; cs . addAllToAttributes ( comparablesAtts ) ; cs . addAllToObservations ( comparablesObjs ) ; cs . addExtentIntent ( "1" , "a" ) ; cs . addExtentIntent ( "2" , "a" ) ; cs . addExtentIntent ( "3" , "b" ) ; cs . addExtentIntent ( "3" , "c" ) ; ConceptLattice result = ConceptLattice . diagramLattice ( cs ) ; assertEquals ( null , ( ( Node ) result . getNodes ( ) . first ( ) ) . getContent ( ) ) ; }
Test of diagramLattice method, of class ConceptLattice.
Test of diagramLattice method of class ConceptLattice .