assertFalse(tx.containsVertexLabel("person")); assertFalse(tx.containsVertexLabel("person")); assertFalse(tx.containsRelationType("value")); assertNull(tx.getPropertyKey("value")); assertTrue(tx.containsRelationType("value")); TitanVertex v = tx.addVertex("person"); assertTrue(tx.containsVertexLabel("person")); assertEquals("person", v.label()); assertFalse(tx.containsRelationType("knows")); assertTrue(tx.containsVertexLabel("person")); assertTrue(tx.containsRelationType("knows")); v = getV(tx, v);
assertTrue(tx.containsVertexLabel("person")); PropertyKey name = tx.getPropertyKey("name"); EdgeLabel knows = tx.getEdgeLabel("knows");
public void testAutomaticTypeCreation() { assertFalse(tx.containsVertexLabel("person")); assertFalse(tx.containsVertexLabel("person")); assertFalse(tx.containsRelationType("value")); assertNull(tx.getPropertyKey("value")); assertTrue(tx.containsRelationType("value")); TitanVertex v = tx.addVertexWithLabel("person"); assertTrue(tx.containsVertexLabel("person")); assertEquals("person",v.getLabel()); assertFalse(tx.containsRelationType("knows")); assertTrue(tx.containsVertexLabel("person")); assertTrue(tx.containsRelationType("knows")); v = tx.getVertex(v.getLongId());
assertTrue(tx.containsVertexLabel("person")); PropertyKey name = tx.getPropertyKey("name"); EdgeLabel knows = tx.getEdgeLabel("knows");