equal
deleted
inserted
replaced
24 |
24 |
25 import random |
25 import random |
26 import threading |
26 import threading |
27 import socket |
27 import socket |
28 |
28 |
|
29 from six import PY3 |
29 from six.moves import range, http_client |
30 from six.moves import range, http_client |
30 from six.moves.urllib.parse import urlparse |
31 from six.moves.urllib.parse import urlparse |
31 |
32 |
32 |
33 |
33 from cubicweb.devtools.testlib import CubicWebTC |
34 from cubicweb.devtools.testlib import CubicWebTC |
130 super(_CubicWebServerTC, self).tearDown() |
131 super(_CubicWebServerTC, self).tearDown() |
131 |
132 |
132 |
133 |
133 class CubicWebServerTC(_CubicWebServerTC): |
134 class CubicWebServerTC(_CubicWebServerTC): |
134 def start_server(self): |
135 def start_server(self): |
|
136 if PY3: |
|
137 self.skipTest('not using twisted on python3') |
135 from twisted.internet import reactor |
138 from twisted.internet import reactor |
136 from cubicweb.etwist.server import run |
139 from cubicweb.etwist.server import run |
137 # use a semaphore to avoid starting test while the http server isn't |
140 # use a semaphore to avoid starting test while the http server isn't |
138 # fully initilialized |
141 # fully initilialized |
139 semaphore = threading.Semaphore(0) |
142 semaphore = threading.Semaphore(0) |