[
https://issues.apache.org/jira/browse/TINKERPOP-2055?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16638564#comment-16638564
]
ASF GitHub Bot commented on TINKERPOP-2055:
-------------------------------------------
Github user spmallette commented on a diff in the pull request:
https://github.com/apache/tinkerpop/pull/947#discussion_r222757984
--- Diff:
gremlin-javascript/src/main/javascript/gremlin-javascript/test/unit/graphson-test.js
---
@@ -46,6 +46,30 @@ describe('GraphSONReader', function () {
assert.strictEqual(result, item[1]);
});
});
+ it('should parse GraphSON Nan from GraphSON', function () {
+ const reader = new GraphSONReader();
+ var result = reader.read({
+ "@type": "g:Double",
+ "@value": "NaN"
+ });
+ assert.ok(isNaN(result));
+ });
+ it('should parse GraphSON -Infinity and Nan from GraphSON', function () {
--- End diff --
just missed the capitlization in that string. i can fix it
> Provide support for special number cases like Infinity in GraphSON
> ------------------------------------------------------------------
>
> Key: TINKERPOP-2055
> URL: https://issues.apache.org/jira/browse/TINKERPOP-2055
> Project: TinkerPop
> Issue Type: Improvement
> Components: io
> Affects Versions: 3.2.9
> Reporter: stephen mallette
> Assignee: stephen mallette
> Priority: Minor
>
> GraphSON currently doesn't handle: {{Double.Nan}},
> {{Double.NEGATIVE_INFINITY}} or {{Double.POSITIVE_INFINITY}} because it has a
> custom {{Double}} serializer that ignores those cases in GraphSON 2.0 and
> 3.0. Not going to try to solve this for 1.0.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)