You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by dk...@apache.org on 2017/09/26 17:28:10 UTC

[28/39] tinkerpop git commit: added a test to ensure ReferenceVertex serialization and deserializtion by Python GraphSON module. Tests pass. CTR.

added a test to ensure ReferenceVertex serialization and deserializtion by Python GraphSON module. Tests pass. CTR.


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/98ed3d41
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/98ed3d41
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/98ed3d41

Branch: refs/heads/TINKERPOP-1782
Commit: 98ed3d419743ffa1a949fd79153e0d8d1a00cd09
Parents: aaa0f14
Author: Marko A. Rodriguez <ok...@gmail.com>
Authored: Thu Sep 21 12:43:53 2017 -0600
Committer: Marko A. Rodriguez <ok...@gmail.com>
Committed: Thu Sep 21 12:43:53 2017 -0600

----------------------------------------------------------------------
 .../gremlin/python/structure/io/graphson/GraphSONReaderTest.java  | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/98ed3d41/gremlin-python/src/test/java/org/apache/tinkerpop/gremlin/python/structure/io/graphson/GraphSONReaderTest.java
----------------------------------------------------------------------
diff --git a/gremlin-python/src/test/java/org/apache/tinkerpop/gremlin/python/structure/io/graphson/GraphSONReaderTest.java b/gremlin-python/src/test/java/org/apache/tinkerpop/gremlin/python/structure/io/graphson/GraphSONReaderTest.java
index 86bdd21..e10d2a6 100644
--- a/gremlin-python/src/test/java/org/apache/tinkerpop/gremlin/python/structure/io/graphson/GraphSONReaderTest.java
+++ b/gremlin-python/src/test/java/org/apache/tinkerpop/gremlin/python/structure/io/graphson/GraphSONReaderTest.java
@@ -62,11 +62,14 @@ public class GraphSONReaderTest {
         jythonEngine.getBindings(ScriptContext.ENGINE_SCOPE).put("x", mapper.writeValueAsString(vertex));
         assertEquals(vertex.toString(), jythonEngine.eval("str(graphson_reader.readObject(x))"));
         assertTrue((Boolean) jythonEngine.eval("isinstance(graphson_reader.readObject(x),Vertex)"));
+        assertEquals("person", jythonEngine.eval("graphson_reader.readObject(x).label"));
+        assertEquals(1, jythonEngine.eval("graphson_reader.readObject(x).id"));
         //
         final Edge edge = g.V(1).outE("created").next();
         jythonEngine.getBindings(ScriptContext.ENGINE_SCOPE).put("x", mapper.writeValueAsString(edge));
         assertEquals(edge.toString(), jythonEngine.eval("str(graphson_reader.readObject(x))"));
         assertTrue((Boolean) jythonEngine.eval("isinstance(graphson_reader.readObject(x),Edge)"));
+        assertEquals("created", jythonEngine.eval("graphson_reader.readObject(x).label"));
         //
         final VertexProperty vertexProperty = (VertexProperty) g.V(1).properties("name").next();
         jythonEngine.getBindings(ScriptContext.ENGINE_SCOPE).put("x", mapper.writeValueAsString(vertexProperty));