@Test
public void testGet() {

    IndexImpl<Node> index = generateEmptyIndex();
    NodeImpl[] nodes = generateNodesWithUniqueAttributes(index, true);
    putAll(nodes, index);
    for (Column col : index.columnStore) {
        if (col.isIndexed()) {
            ObjectSet<Object> set = new ObjectOpenHashSet<Object>();
            for (NodeImpl n : nodes) {
                Object obj = n.getAttribute(col);
                set.add(obj);
            }
            for (Object value : set) {
                ObjectSet actual1 = new ObjectOpenHashSet(getIterable(index.get(col, value)));
                ObjectSet actual2 = new ObjectOpenHashSet(getIterable(index.get(col.getId(), value)));
                ObjectSet expected = new ObjectOpenHashSet();
                for (NodeImpl n : nodes) {
                    Object v = n.getAttribute(col);
                    if ((v == null && value == null) || (v != null && v.equals(value))) {
                        expected.add(n);
                    }
                }
                Assert.assertEquals(actual1, expected);
                Assert.assertEquals(actual2, expected);
            }
            for (Map.Entry<Object, Set<Node>> entry : index.get(col)) {
                Object value = entry.getKey();
                Set<Node> actual = entry.getValue();
                ObjectSet expected = new ObjectOpenHashSet();
                for (NodeImpl n : nodes) {
                    Object v = n.getAttribute(col);
                    if ((v == null && value == null) || (v != null && v.equals(value))) {
                        expected.add(n);
                    }
                }
                Assert.assertEquals(actual, expected);
            }
        }
    }
}