Skip to content

Commit 351f454

Browse files
committed
Add tox for multi-python testing, fix python3 bug
1 parent e7ed2e8 commit 351f454

File tree

3 files changed

+16
-1
lines changed

3 files changed

+16
-1
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@
88
*.snap
99
sophia
1010
*.egg-info
11+
.tox

tests/suites/test_dml.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ def test_10_space(self):
236236
def test_11_select_all_hash(self):
237237
space = self.con.space('space_2')
238238
cnt = 10
239-
for k in xrange(cnt):
239+
for k in range(cnt):
240240
space.insert([k, 'lol'])
241241
self.assertEqual(len(space.select(())), cnt)
242242
self.assertEqual(len(space.select([])), cnt)

tox.ini

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Tox (http://tox.testrun.org/) is a tool for running tests
2+
# in multiple virtualenvs. This configuration file will run the
3+
# test suite on all supported python versions. To use it, "pip install tox"
4+
# and then run "tox" from this directory.
5+
6+
[tox]
7+
envlist = py27, py35, pypy
8+
9+
[testenv]
10+
commands = python setup.py test
11+
deps =
12+
pyyaml>=3.10
13+
msgpack-python>=0.4.0
14+
six

0 commit comments

Comments
 (0)