Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Support for py2.6 tests.

  • Loading branch information...
commit 084c70425e76c7659970e2ac02e660b97ff316db 1 parent 8e1e25b
@ralphbean authored
Showing with 26 additions and 9 deletions.
  1. +8 −3 fedmsg/tests/fedmsg-test-config.py
  2. +3 −0  setup.cfg
  3. +15 −6 setup.py
View
11 fedmsg/tests/fedmsg-test-config.py
@@ -1,13 +1,18 @@
""" Test config. """
import socket
+import random
+
hostname = socket.gethostname()
+# Pick random ports for the tests so travis-ci doesn't flip out.
+port = random.randint(4000, 20000)
+
config = dict(
endpoints={
- "unittest.%s" % hostname: ["tcp://*:98765"],
- "twisted.%s" % hostname: ["tcp://*:98764"],
+ "unittest.%s" % hostname: ["tcp://*:%i" % (port + 1)],
+ "twisted.%s" % hostname: ["tcp://*:%i" % (port + 2)],
},
- relay_inbound="tcp://127.0.0.1:2003",
+ relay_inbound="tcp://127.0.0.1:%i" % (port - 1),
environment="dev",
high_water_mark=0,
io_threads=1,
View
3  setup.cfg
@@ -0,0 +1,3 @@
+[nosetests]
+
+where=fedmsg/tests
View
21 setup.py
@@ -7,6 +7,8 @@
use_setuptools()
from setuptools import setup
+import sys
+
f = open('README.rst')
long_description = f.read().strip()
long_description = long_description.split('split here', 1)[1]
@@ -20,6 +22,18 @@
except Exception:
pass
+
+install_requires = [
+ 'pyzmq',
+ 'simplejson',
+ 'fabulous',
+ 'moksha>=0.8.0',
+]
+
+if sys.version_info[0] == 2 and sys.version_info[1] <= 6:
+ install_requires.append('argparse')
+
+
setup(
name='fedmsg',
version='0.1.6',
@@ -29,12 +43,7 @@
author_email='rbean@redhat.com',
url='http://github.com/ralphbean/fedmsg/',
license='LGPLv2+',
- install_requires=[
- 'pyzmq',
- 'simplejson',
- 'fabulous',
- 'moksha>=0.8.0',
- ],
+ install_requires=install_requires,
tests_require=[
'nose',
],
Please sign in to comment.
Something went wrong with that request. Please try again.