Skip Tor tests on Windows

This commit is contained in:
Sajith Sasidharan 2020-06-22 20:16:19 -04:00
parent 9b68b484bd
commit 7d93ae9213
2 changed files with 13 additions and 0 deletions

View File

@ -359,6 +359,10 @@ def bob(reactor, temp_dir, introducer_furl, flog_gatherer, storage_nodes, reques
@pytest.fixture(scope='session') @pytest.fixture(scope='session')
def chutney(reactor, temp_dir): def chutney(reactor, temp_dir):
if sys.platform.startswith('win'):
pytest.skip('Tor tests are unstable on Windows')
chutney_dir = join(temp_dir, 'chutney') chutney_dir = join(temp_dir, 'chutney')
mkdir(chutney_dir) mkdir(chutney_dir)
@ -389,6 +393,10 @@ def chutney(reactor, temp_dir):
@pytest.fixture(scope='session') @pytest.fixture(scope='session')
def tor_network(reactor, temp_dir, chutney, request): def tor_network(reactor, temp_dir, chutney, request):
if sys.platform.startswith('win'):
pytest.skip('Tor tests are unstable on Windows')
# this is the actual "chutney" script at the root of a chutney checkout # this is the actual "chutney" script at the root of a chutney checkout
chutney_dir = chutney chutney_dir = chutney
chut = join(chutney_dir, 'chutney') chut = join(chutney_dir, 'chutney')

View File

@ -10,12 +10,17 @@ from six.moves import StringIO
from twisted.internet.protocol import ProcessProtocol from twisted.internet.protocol import ProcessProtocol
from twisted.internet.error import ProcessExitedAlready, ProcessDone from twisted.internet.error import ProcessExitedAlready, ProcessDone
from twisted.internet.defer import inlineCallbacks, Deferred from twisted.internet.defer import inlineCallbacks, Deferred
import pytest
import pytest_twisted import pytest_twisted
import util import util
# see "conftest.py" for the fixtures (e.g. "tor_network") # see "conftest.py" for the fixtures (e.g. "tor_network")
if sys.platform.startswith('win'):
pytest.skip('Skipping Tor tests on Windows', allow_module_level=True)
@pytest_twisted.inlineCallbacks @pytest_twisted.inlineCallbacks
def test_onion_service_storage(reactor, request, temp_dir, flog_gatherer, tor_network, tor_introducer_furl): def test_onion_service_storage(reactor, request, temp_dir, flog_gatherer, tor_network, tor_introducer_furl):
yield _create_anonymous_node(reactor, 'carol', 8008, request, temp_dir, flog_gatherer, tor_network, tor_introducer_furl) yield _create_anonymous_node(reactor, 'carol', 8008, request, temp_dir, flog_gatherer, tor_network, tor_introducer_furl)