You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by jo...@apache.org on 2017/11/23 09:21:01 UTC

[23/50] [abbrv] tinkerpop git commit: TINKERPOP-1784 Added support for BigDecimal and fixed broken tests

TINKERPOP-1784 Added support for BigDecimal and fixed broken tests


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

Branch: refs/heads/TINKERPOP-1489
Commit: 7231b5a61c851cd3065cb63844e94b9d8d1466ea
Parents: 014d552
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Fri Nov 17 12:35:28 2017 -0500
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Tue Nov 21 15:53:14 2017 -0500

----------------------------------------------------------------------
 gremlin-python/src/main/jython/radish/feature_steps.py | 4 ++--
 gremlin-test/features/branch/Local.feature             | 2 +-
 gremlin-test/features/branch/Repeat.feature            | 2 +-
 gremlin-test/features/map/Mean.feature                 | 2 +-
 gremlin-test/features/map/Min.feature                  | 2 +-
 gremlin-test/features/map/Order.feature                | 2 +-
 gremlin-test/features/map/Properties.feature           | 2 +-
 gremlin-test/features/sideEffect/Group.feature         | 2 +-
 gremlin-test/features/sideEffect/Sack.feature          | 2 +-
 9 files changed, 10 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-python/src/main/jython/radish/feature_steps.py
----------------------------------------------------------------------
diff --git a/gremlin-python/src/main/jython/radish/feature_steps.py b/gremlin-python/src/main/jython/radish/feature_steps.py
index 9f00535..5cb4b9a 100644
--- a/gremlin-python/src/main/jython/radish/feature_steps.py
+++ b/gremlin-python/src/main/jython/radish/feature_steps.py
@@ -136,8 +136,8 @@ def _convert(val, ctx):
         return list(map((lambda x: _convert(x, ctx)), val[2:-1].split(",")))
     elif isinstance(val, str) and re.match("^s\[.*\]$", val):         # parse set
         return set(map((lambda x: _convert(x, ctx)), val[2:-1].split(",")))
-    elif isinstance(val, str) and re.match("^d\[.*\][ilfd]$", val):   # parse numeric
-        return float(val[2:-1]) if val[2:-1].__contains__(".") else long(val[2:-1])
+    elif isinstance(val, str) and re.match("^d\[.*\]\.[ilfdm]$", val):  # parse numeric
+        return float(val[2:-3]) if val[2:-3].__contains__(".") else long(val[2:-3])
     elif isinstance(val, str) and re.match("^v\[.*\]\.id$", val):     # parse vertex id
         return ctx.lookup_v["modern"][val[2:-4]].id
     elif isinstance(val, str) and re.match("^v\[.*\]\.sid$", val):    # parse vertex id as string

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/branch/Local.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/branch/Local.feature b/gremlin-test/features/branch/Local.feature
index d6e809e..9efe921 100644
--- a/gremlin-test/features/branch/Local.feature
+++ b/gremlin-test/features/branch/Local.feature
@@ -47,7 +47,7 @@ Feature: Step - local()
       | m[{"a":"marko","b":"d[3].i"}] |
       | m[{"a":"josh","b":"d[5].i"}]  |
       | m[{"a":"josh","b":"d[3].i"}]  |
-      | m[{"a":"peter","b":"d[3].i}] |
+      | m[{"a":"peter","b":"d[3].i"}] |
 
   Scenario: g_V_localXoutE_countX
     Given the modern graph

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/branch/Repeat.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/branch/Repeat.feature b/gremlin-test/features/branch/Repeat.feature
index 89eb002..009c380 100644
--- a/gremlin-test/features/branch/Repeat.feature
+++ b/gremlin-test/features/branch/Repeat.feature
@@ -212,7 +212,7 @@ Feature: Step - repeat()
     When iterated to list
     Then the result should be unordered
       | result |
-      | m[{"ripple":"d[3].l,"vadas":"d[3].l","josh":"d[4].l","lop":"d[10].l","marko":"d[4].l"}] |
+      | m[{"ripple":"d[3].l","vadas":"d[3].l","josh":"d[4].l","lop":"d[10].l","marko":"d[4].l"}] |
 
   Scenario: g_V_hasXname_markoX_repeatXoutE_inV_simplePathX_untilXhasXname_rippleXX_path_byXnameX_byXlabelX
     Given the modern graph

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/map/Mean.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/map/Mean.feature b/gremlin-test/features/map/Mean.feature
index b716bde..b109356 100644
--- a/gremlin-test/features/map/Mean.feature
+++ b/gremlin-test/features/map/Mean.feature
@@ -37,4 +37,4 @@ Feature: Step - mean()
     When iterated to list
     Then the result should be unordered
       | result |
-      | m[{"ripple":"d[1.0]".d,"lop":"d[0.3333333333333333].d"}] |
\ No newline at end of file
+      | m[{"ripple":"d[1.0].d","lop":"d[0.3333333333333333].d"}] |
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/map/Min.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/map/Min.feature b/gremlin-test/features/map/Min.feature
index 3cdb7e3..203a6f1 100644
--- a/gremlin-test/features/map/Min.feature
+++ b/gremlin-test/features/map/Min.feature
@@ -48,4 +48,4 @@ Feature: Step - min()
     When iterated to list
     Then the result should be unordered
       | result |
-      | m[{"ripple":"d[1.0].d","lop":"d[0.2]d"}] |
+      | m[{"ripple":"d[1.0].d","lop":"d[0.2].d"}] |

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/map/Order.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/map/Order.feature b/gremlin-test/features/map/Order.feature
index 879bfd0..976906f 100644
--- a/gremlin-test/features/map/Order.feature
+++ b/gremlin-test/features/map/Order.feature
@@ -97,7 +97,7 @@ Feature: Step - order()
       | d[0.5].d |
       | d[0.4].d |
       | d[0.4].d |
-      | d[0.2].d] |
+      | d[0.2].d |
 
   Scenario: g_V_order_byXname_a1_b1X_byXname_b2_a2X_name
     Given the modern graph

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/map/Properties.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/map/Properties.feature b/gremlin-test/features/map/Properties.feature
index 88f8d70..58a5531 100644
--- a/gremlin-test/features/map/Properties.feature
+++ b/gremlin-test/features/map/Properties.feature
@@ -33,7 +33,7 @@ Feature: Step - properties()
       | josh  |
       | d[32].i |
       | peter |
-      | d[35.i] |
+      | d[35].i |
 
   Scenario: g_V_hasXageX_propertiesXage_nameX_value
     Given the modern graph

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/sideEffect/Group.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/sideEffect/Group.feature b/gremlin-test/features/sideEffect/Group.feature
index 3b9bb11..72cc86b 100644
--- a/gremlin-test/features/sideEffect/Group.feature
+++ b/gremlin-test/features/sideEffect/Group.feature
@@ -101,7 +101,7 @@ Feature: Step - group()
     When iterated to list
     Then the result should be unordered
       | result |
-      | m[{"software":"d[0].i", "person":"d[3.5].d}] |
+      | m[{"software":"d[0].i", "person":"d[3.5].d"}] |
 
   Scenario: g_V_repeatXbothXfollowedByXX_timesX2X_group_byXsongTypeX_byXcountX
     Given the grateful graph

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/7231b5a6/gremlin-test/features/sideEffect/Sack.feature
----------------------------------------------------------------------
diff --git a/gremlin-test/features/sideEffect/Sack.feature b/gremlin-test/features/sideEffect/Sack.feature
index 487f31b..d83d7e1 100644
--- a/gremlin-test/features/sideEffect/Sack.feature
+++ b/gremlin-test/features/sideEffect/Sack.feature
@@ -42,7 +42,7 @@ Feature: Step - sack()
     When iterated to list
     Then the result should be unordered
       | result |
-      | d[3.5].d |
+      | d[3.5].m |
 
   Scenario: g_withSackX0X_V_repeatXoutE_sackXsumX_byXweightX_inVX_timesX2X_sack
     Given the modern graph