Skip to content

Commit 3a92622

Browse files
committed
Renamed urlfetch adapter test and made it import unittest2 if v2.6
1 parent ab6e93e commit 3a92622

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,5 @@ install:
1010
- "pip install aiohttp"
1111
- "pip install tornado"
1212
- "pip install urlfetch"
13+
- if [[ $TRAVIS_PYTHON_VERSION == '2.6' ]]; then pip install unittest2; fi
1314
script: "python setup.py test"

pusher_tests/urlfetch_adapter_test.py renamed to pusher_tests/test_urlfetch_adapter.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,14 @@
33
from __future__ import print_function, absolute_import, division
44

55
import pusher
6-
import unittest
76
import httpretty
87
import sys
98

9+
if (sys.version_info < (2,7)):
10+
import unittest2 as unittest
11+
else:
12+
import unittest
13+
1014
@unittest.skipIf(sys.version_info >= (3,), "skip")
1115
class TestURLFetchBackend(unittest.TestCase):
1216

0 commit comments

Comments
 (0)