You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by da...@apache.org on 2017/04/10 20:43:51 UTC
[1/3] tinkerpop git commit: removed unittest from gremlin-python tests
Repository: tinkerpop
Updated Branches:
refs/heads/tp32 021831eda -> 2436a69e9
removed unittest from gremlin-python tests
Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/d0686829
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/d0686829
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/d0686829
Branch: refs/heads/tp32
Commit: d06868292d7f2592772dac2f15281fe2803cc328
Parents: 95d3efc
Author: davebshow <da...@gmail.com>
Authored: Tue Apr 4 22:02:08 2017 -0400
Committer: davebshow <da...@gmail.com>
Committed: Tue Apr 4 22:02:08 2017 -0400
----------------------------------------------------------------------
.../src/main/jython/tests/process/test_strategies.py | 8 +-------
.../src/main/jython/tests/process/test_traversal.py | 9 +--------
.../src/main/jython/tests/structure/io/test_graphson.py | 10 ++--------
.../src/main/jython/tests/structure/test_graph.py | 9 +--------
gremlin-python/src/main/jython/tests/test_statics.py | 9 +--------
5 files changed, 6 insertions(+), 39 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0686829/gremlin-python/src/main/jython/tests/process/test_strategies.py
----------------------------------------------------------------------
diff --git a/gremlin-python/src/main/jython/tests/process/test_strategies.py b/gremlin-python/src/main/jython/tests/process/test_strategies.py
index 6d1d2c3..008ec80 100644
--- a/gremlin-python/src/main/jython/tests/process/test_strategies.py
+++ b/gremlin-python/src/main/jython/tests/process/test_strategies.py
@@ -19,15 +19,12 @@ under the License.
__author__ = 'Marko A. Rodriguez (http://markorodriguez.com)'
-import unittest
-from unittest import TestCase
-
from gremlin_python.structure.graph import Graph
from gremlin_python.process.strategies import *
from gremlin_python.process.graph_traversal import __
-class TestTraversalStrategies(TestCase):
+class TestTraversalStrategies(object):
def test_singletons(self):
g = Graph().traversal()
bytecode = g.withStrategies(ReadOnlyStrategy()).bytecode
@@ -101,6 +98,3 @@ class TestTraversalStrategies(TestCase):
strategy = bytecode.source_instructions[0][1]
assert 1 == len(strategy.configuration)
assert __.has("name","marko") == strategy.configuration["vertices"]
-
-if __name__ == '__main__':
- unittest.main()
http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0686829/gremlin-python/src/main/jython/tests/process/test_traversal.py
----------------------------------------------------------------------
diff --git a/gremlin-python/src/main/jython/tests/process/test_traversal.py b/gremlin-python/src/main/jython/tests/process/test_traversal.py
index eb652f4..aba7781 100644
--- a/gremlin-python/src/main/jython/tests/process/test_traversal.py
+++ b/gremlin-python/src/main/jython/tests/process/test_traversal.py
@@ -19,16 +19,13 @@ under the License.
__author__ = 'Marko A. Rodriguez (http://markorodriguez.com)'
-import unittest
-from unittest import TestCase
-
from gremlin_python.structure.graph import Graph
from gremlin_python.process.traversal import P
from gremlin_python.process.traversal import Binding
from gremlin_python.process.graph_traversal import __
-class TestTraversal(TestCase):
+class TestTraversal(object):
def test_bytecode(self):
g = Graph().traversal()
bytecode = g.V().out("created").bytecode
@@ -85,7 +82,3 @@ class TestTraversal(TestCase):
assert 0 == len(bytecode.bindings.keys())
assert 0 == len(bytecode.source_instructions)
assert 0 == len(bytecode.step_instructions)
-
-
-if __name__ == '__main__':
- unittest.main()
http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0686829/gremlin-python/src/main/jython/tests/structure/io/test_graphson.py
----------------------------------------------------------------------
diff --git a/gremlin-python/src/main/jython/tests/structure/io/test_graphson.py b/gremlin-python/src/main/jython/tests/structure/io/test_graphson.py
index 7bca769..07381bf 100644
--- a/gremlin-python/src/main/jython/tests/structure/io/test_graphson.py
+++ b/gremlin-python/src/main/jython/tests/structure/io/test_graphson.py
@@ -21,8 +21,6 @@ __author__ = 'Marko A. Rodriguez (http://markorodriguez.com)'
import json
from mock import Mock
-import unittest
-from unittest import TestCase
import six
@@ -36,7 +34,7 @@ from gremlin_python.process.strategies import SubgraphStrategy
from gremlin_python.process.graph_traversal import __
-class TestGraphSONReader(TestCase):
+class TestGraphSONReader(object):
graphson_reader = GraphSONReader()
def test_number_input(self):
@@ -124,7 +122,7 @@ class TestGraphSONReader(TestCase):
assert o is serdes.objectify()
-class TestGraphSONWriter(TestCase):
+class TestGraphSONWriter(object):
graphson_writer = GraphSONWriter()
@@ -205,7 +203,3 @@ class TestGraphSONWriter(TestCase):
mapping = self.graphson_writer.toDict(long(1))
assert mapping['@type'] == 'g:Int64'
assert mapping['@value'] == 1
-
-
-if __name__ == '__main__':
- unittest.main()
http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0686829/gremlin-python/src/main/jython/tests/structure/test_graph.py
----------------------------------------------------------------------
diff --git a/gremlin-python/src/main/jython/tests/structure/test_graph.py b/gremlin-python/src/main/jython/tests/structure/test_graph.py
index c619ad2..766161b 100644
--- a/gremlin-python/src/main/jython/tests/structure/test_graph.py
+++ b/gremlin-python/src/main/jython/tests/structure/test_graph.py
@@ -19,9 +19,6 @@ under the License.
__author__ = 'Marko A. Rodriguez (http://markorodriguez.com)'
-import unittest
-from unittest import TestCase
-
import six
from gremlin_python.statics import long
@@ -32,7 +29,7 @@ from gremlin_python.structure.graph import VertexProperty
from gremlin_python.structure.graph import Path
-class TestGraph(TestCase):
+class TestGraph(object):
def test_graph_objects(self):
vertex = Vertex(1)
assert "v[1]" == str(vertex)
@@ -114,7 +111,3 @@ class TestGraph(TestCase):
assert hash(path) == hash(path2)
assert path != Path([set(["a"]), set(["c", "b"]), set([])], [1, Vertex(1), "hello"])
assert path != Path([set(["a", "b"]), set(["c", "b"]), set([])], [3, Vertex(1), "hello"])
-
-
-if __name__ == '__main__':
- unittest.main()
http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/d0686829/gremlin-python/src/main/jython/tests/test_statics.py
----------------------------------------------------------------------
diff --git a/gremlin-python/src/main/jython/tests/test_statics.py b/gremlin-python/src/main/jython/tests/test_statics.py
index 75fae2d..3e0b24c 100644
--- a/gremlin-python/src/main/jython/tests/test_statics.py
+++ b/gremlin-python/src/main/jython/tests/test_statics.py
@@ -19,16 +19,13 @@ under the License.
__author__ = 'Marko A. Rodriguez (http://markorodriguez.com)'
-import unittest
-from unittest import TestCase
-
from gremlin_python import statics
from gremlin_python.process.traversal import Cardinality
from gremlin_python.process.traversal import P
from gremlin_python.process.traversal import Pop
-class TestStatics(TestCase):
+class TestStatics(object):
def test_enums(self):
statics.load_statics(globals())
assert isinstance(list_, Cardinality)
@@ -40,7 +37,3 @@ class TestStatics(TestCase):
assert isinstance(first, Pop)
assert first == Pop.first
statics.unload_statics(globals())
-
-
-if __name__ == '__main__':
- unittest.main()
[3/3] tinkerpop git commit: Merge branch 'TINKERPOP-1665' into tp32
Posted by da...@apache.org.
Merge branch 'TINKERPOP-1665' into tp32
Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/2436a69e
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/2436a69e
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/2436a69e
Branch: refs/heads/tp32
Commit: 2436a69e90006b4b2f231334baaf37358339f3cf
Parents: 021831e e745fb0
Author: davebshow <da...@gmail.com>
Authored: Mon Apr 10 16:40:03 2017 -0400
Committer: davebshow <da...@gmail.com>
Committed: Mon Apr 10 16:40:03 2017 -0400
----------------------------------------------------------------------
gremlin-console/src/test/python/tests/test_console.py | 8 ++------
.../src/main/jython/tests/process/test_strategies.py | 8 +-------
.../src/main/jython/tests/process/test_traversal.py | 9 +--------
.../src/main/jython/tests/structure/io/test_graphson.py | 10 ++--------
.../src/main/jython/tests/structure/test_graph.py | 9 +--------
gremlin-python/src/main/jython/tests/test_statics.py | 9 +--------
6 files changed, 8 insertions(+), 45 deletions(-)
----------------------------------------------------------------------
[2/3] tinkerpop git commit: removed unittest
Posted by da...@apache.org.
removed unittest
Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/e745fb06
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/e745fb06
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/e745fb06
Branch: refs/heads/tp32
Commit: e745fb06f82559e8917a51b80a24dbd29c1f9d79
Parents: d068682
Author: davebshow <da...@gmail.com>
Authored: Wed Apr 5 09:30:34 2017 -0400
Committer: davebshow <da...@gmail.com>
Committed: Wed Apr 5 09:30:34 2017 -0400
----------------------------------------------------------------------
gremlin-console/src/test/python/tests/test_console.py | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/e745fb06/gremlin-console/src/test/python/tests/test_console.py
----------------------------------------------------------------------
diff --git a/gremlin-console/src/test/python/tests/test_console.py b/gremlin-console/src/test/python/tests/test_console.py
index c2719bd..f079291 100644
--- a/gremlin-console/src/test/python/tests/test_console.py
+++ b/gremlin-console/src/test/python/tests/test_console.py
@@ -17,11 +17,10 @@ specific language governing permissions and limitations
under the License.
'''
-import unittest
-from unittest import TestCase
import pexpect
-class TestConsole(TestCase):
+
+class TestConsole(object):
# the base command must pass -C because if colors are enabled pexpect gets garbled input and tests won't pass
gremlinsh = "bash gremlin-console/bin/gremlin.sh -C "
@@ -90,6 +89,3 @@ class TestConsole(TestCase):
@staticmethod
def _close(child):
child.sendline(":x")
-
-
-