mirror of
https://github.com/balkian/bitter.git
synced 2024-12-22 00:18:12 +00:00
Fix tests py2
This commit is contained in:
parent
bdb844d75f
commit
fadeced761
@ -2,6 +2,6 @@
|
|||||||
From python:2.7-onbuild
|
From python:2.7-onbuild
|
||||||
Maintainer J. Fernando Sánchez @balkian
|
Maintainer J. Fernando Sánchez @balkian
|
||||||
|
|
||||||
RUN pip install -e "/usr/src/app/[server]"
|
RUN pip install ".[server]"
|
||||||
|
|
||||||
ENTRYPOINT ["bitter"]
|
ENTRYPOINT ["bitter"]
|
||||||
|
2
Makefile
2
Makefile
@ -1,4 +1,4 @@
|
|||||||
PYVERSIONS=3.4 2.7
|
PYVERSIONS=3.5
|
||||||
PYMAIN=$(firstword $(PYVERSIONS))
|
PYMAIN=$(firstword $(PYVERSIONS))
|
||||||
NAME=bitter
|
NAME=bitter
|
||||||
REPO=balkian
|
REPO=balkian
|
||||||
|
@ -50,11 +50,11 @@ class TestUtils(TestCase):
|
|||||||
tic = time.time()
|
tic = time.time()
|
||||||
resp = utils.parallel(echo, [1, 2, 3])
|
resp = utils.parallel(echo, [1, 2, 3])
|
||||||
assert isinstance(resp, types.GeneratorType)
|
assert isinstance(resp, types.GeneratorType)
|
||||||
assert list(resp) == [1,2,3]
|
assert sorted(list(resp)) == [1, 2, 3]
|
||||||
toc = time.time()
|
toc = time.time()
|
||||||
assert (tic-toc) < 600
|
assert (tic-toc) < 600
|
||||||
resp2 = utils.parallel(echo, [1,2,3,4], chunksize=2)
|
resp2 = utils.parallel(echo, [1,2,3,4], chunksize=2)
|
||||||
assert list(resp2) == [1,2, 3,4]
|
assert sorted(list(resp2)) == [1, 2, 3, 4]
|
||||||
|
|
||||||
|
|
||||||
class TestUtilsEnv(TestUtils):
|
class TestUtilsEnv(TestUtils):
|
||||||
|
Loading…
Reference in New Issue
Block a user