tinkerpop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ok...@apache.org
Subject [16/50] incubator-tinkerpop git commit: Converted int to double for tests consistency reasons.
Date Thu, 03 Dec 2015 16:43:12 GMT
Converted int to double for tests consistency reasons.


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

Branch: refs/heads/TINKERPOP3-982
Commit: 7626967d01309b3732345ee7d9532e8a5677c647
Parents: fd95dc8
Author: Nghia Tran <nghia.tran.83@gmail.com>
Authored: Fri Nov 27 16:32:42 2015 -0500
Committer: Nghia Tran <nghia.tran.83@gmail.com>
Committed: Fri Nov 27 16:32:42 2015 -0500

----------------------------------------------------------------------
 .../process/traversal/step/map/GroovyAddEdgeTest.groovy      | 4 ++--
 .../gremlin/process/traversal/step/map/AddEdgeTest.java      | 8 ++++----
 2 files changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/7626967d/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/map/GroovyAddEdgeTest.groovy
----------------------------------------------------------------------
diff --git a/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/map/GroovyAddEdgeTest.groovy
b/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/map/GroovyAddEdgeTest.groovy
index 176e731..eb78aa2 100644
--- a/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/map/GroovyAddEdgeTest.groovy
+++ b/gremlin-groovy-test/src/main/groovy/org/apache/tinkerpop/gremlin/process/traversal/step/map/GroovyAddEdgeTest.groovy
@@ -38,7 +38,7 @@ public abstract class GroovyAddEdgeTest {
         @Override
         public Traversal<Vertex, Edge> get_g_VX1X_asXaX_outXcreatedX_addEXcreatedByX_toXaX_propertyXweight_2X(
                 final Object v1Id) {
-            TraversalScriptHelper.compute("g.V(v1Id).as('a').out('created').addE('createdBy').to('a').property('weight',
2)", g, "v1Id", v1Id)
+            TraversalScriptHelper.compute("g.V(v1Id).as('a').out('created').addE('createdBy').to('a').property('weight',
2.0d)", g, "v1Id", v1Id)
         }
 
         @Override
@@ -64,7 +64,7 @@ public abstract class GroovyAddEdgeTest {
         @Override
         public Traversal<Vertex, Edge> get_g_VX1X_asXaX_outXcreatedX_addOutEXcreatedBy_a_weight_2X(
                 final Object v1Id) {
-            TraversalScriptHelper.compute("g.V(v1Id).as('a').out('created').addOutE('createdBy',
'a', 'weight', 2)", g, "v1Id", v1Id)
+            TraversalScriptHelper.compute("g.V(v1Id).as('a').out('created').addOutE('createdBy',
'a', 'weight', 2.0d)", g, "v1Id", v1Id)
         }
 
         @Override

http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/7626967d/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/map/AddEdgeTest.java
----------------------------------------------------------------------
diff --git a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/map/AddEdgeTest.java
b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/map/AddEdgeTest.java
index f3cb90f..9bd6695 100644
--- a/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/map/AddEdgeTest.java
+++ b/gremlin-test/src/main/java/org/apache/tinkerpop/gremlin/process/traversal/step/map/AddEdgeTest.java
@@ -121,7 +121,7 @@ public abstract class AddEdgeTest extends AbstractGremlinProcessTest {
         while (traversal.hasNext()) {
             final Edge edge = traversal.next();
             assertEquals("createdBy", edge.label());
-            assertEquals(2, edge.<Integer>value("weight").intValue());
+            assertEquals(2.0d, edge.<Double>value("weight").doubleValue(),0.00001d);
             assertEquals(1, IteratorUtils.count(edge.properties()));
             count++;
 
@@ -142,7 +142,7 @@ public abstract class AddEdgeTest extends AbstractGremlinProcessTest {
         while (traversal.hasNext()) {
             final Edge edge = traversal.next();
             assertEquals("createdBy", edge.label());
-            assertEquals(2, edge.<Integer>value("weight").intValue());
+            assertEquals(2.0d, edge.<Double>value("weight").doubleValue(),0.00001d);
             assertEquals(1, IteratorUtils.count(edge.properties()));
             count++;
 
@@ -311,7 +311,7 @@ public abstract class AddEdgeTest extends AbstractGremlinProcessTest {
 
         @Override
         public Traversal<Vertex, Edge> get_g_VX1X_asXaX_outXcreatedX_addEXcreatedByX_toXaX_propertyXweight_2X(final
Object v1Id) {
-            return g.V(v1Id).as("a").out("created").addE("createdBy").to("a").property("weight",
2);
+            return g.V(v1Id).as("a").out("created").addE("createdBy").to("a").property("weight",
2.0d);
         }
 
         @Override
@@ -338,7 +338,7 @@ public abstract class AddEdgeTest extends AbstractGremlinProcessTest {
 
         @Override
         public Traversal<Vertex, Edge> get_g_VX1X_asXaX_outXcreatedX_addOutEXcreatedBy_a_weight_2X(final
Object v1Id) {
-            return g.V(v1Id).as("a").out("created").addOutE("createdBy", "a", "weight", 2);
+            return g.V(v1Id).as("a").out("created").addOutE("createdBy", "a", "weight", 2.0d);
         }
 
         @Override


Mime
View raw message