diff options
author | Joshua Marshall <catchjosh@gmail.com> | 2015-10-05 17:17:16 -0700 |
---|---|---|
committer | Joshua Marshall <catchjosh@gmail.com> | 2015-10-05 17:17:16 -0700 |
commit | a39d1f9debff84b2097a2788896ad61867ad1a0e (patch) | |
tree | d2da5ea2bb5fdd7c0636f294ca843aeee83520cb /tests.py | |
parent | ce0c9e2814ec184cd2e29b1010c085482f72aa1b (diff) | |
download | jsonrpclib-a39d1f9debff84b2097a2788896ad61867ad1a0e.tar.gz |
Adding unittest2 for Python <= 2.6
Diffstat (limited to 'tests.py')
-rw-r--r-- | tests.py | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -25,7 +25,8 @@ from jsonrpclib.SimpleJSONRPCServer import SimpleJSONRPCServer from jsonrpclib.SimpleJSONRPCServer import SimpleJSONRPCRequestHandler import socket import tempfile -import unittest +import sys + import os try: import json @@ -33,6 +34,11 @@ except ImportError: import simplejson as json from threading import Thread +if sys.version_info < (2, 7): + import unittest2 as unittest +else: + import unittest + PORTS = range(8000, 8999) |