@Test public void shouldAppendPartitionToEdge() { final Vertex v1 = g.addVertex("any", "thing"); final Vertex v2 = g.addVertex("some", "thing"); final Edge e = v1.addEdge("connectsTo", v2, "every", "thing"); assertNotNull(v1); assertEquals("thing", v1.property("any").value()); assertEquals("A", v2.property(partition).value()); assertNotNull(v2); assertEquals("thing", v2.property("some").value()); assertEquals("A", v2.property(partition).value()); assertNotNull(e); assertEquals("thing", e.property("every").value()); assertEquals("connectsTo", e.label()); assertEquals("A", e.property(partition).value()); }
@Test public void shouldWrapProperties() { final Vertex v = g.addVertex("any", "a"); final Edge e = v.addEdge("to", v, "all", "a"); assertTrue(v.property("any") instanceof StrategyWrappedProperty); assertTrue(v.properties().get("any") instanceof StrategyWrappedProperty); assertTrue(e.property("all") instanceof StrategyWrappedProperty); assertTrue(e.properties().get("all") instanceof StrategyWrappedProperty); assertTrue(g.V().property("any").next() instanceof StrategyWrappedProperty); assertTrue(g.E().property("any").next() instanceof StrategyWrappedProperty); }