mirror of
https://github.com/nvbn/thefuck.git
synced 2025-01-31 02:01:13 +00:00
Fix skipif on fish tests
This commit is contained in:
parent
2291a5ba5d
commit
b2457d1587
@ -1,7 +1,7 @@
|
||||
import pytest
|
||||
from tests.functional.plots import with_confirmation, without_confirmation, \
|
||||
refuse_with_confirmation
|
||||
from tests.functional.utils import spawn, images, bare, enabled
|
||||
from tests.functional.utils import spawn, functional, images, bare
|
||||
|
||||
containers = images(('ubuntu-python3-fish', u'''
|
||||
FROM ubuntu:latest
|
||||
@ -18,8 +18,9 @@ RUN pip2 install -U pip setuptools
|
||||
'''))
|
||||
|
||||
|
||||
@functional
|
||||
@pytest.mark.skipif(
|
||||
bare or not enabled, 'https://github.com/travis-ci/apt-source-whitelist/issues/71')
|
||||
bare, reason='https://github.com/travis-ci/apt-source-whitelist/issues/71')
|
||||
@pytest.mark.parametrize('tag, dockerfile', containers)
|
||||
def test_with_confirmation(tag, dockerfile):
|
||||
with spawn(tag, dockerfile, u'fish') as proc:
|
||||
@ -28,8 +29,9 @@ def test_with_confirmation(tag, dockerfile):
|
||||
with_confirmation(proc)
|
||||
|
||||
|
||||
@functional
|
||||
@pytest.mark.skipif(
|
||||
bare or not enabled, 'https://github.com/travis-ci/apt-source-whitelist/issues/71')
|
||||
bare, reason='https://github.com/travis-ci/apt-source-whitelist/issues/71')
|
||||
@pytest.mark.parametrize('tag, dockerfile', containers)
|
||||
def test_refuse_with_confirmation(tag, dockerfile):
|
||||
with spawn(tag, dockerfile, u'fish') as proc:
|
||||
@ -38,8 +40,9 @@ def test_refuse_with_confirmation(tag, dockerfile):
|
||||
refuse_with_confirmation(proc)
|
||||
|
||||
|
||||
@functional
|
||||
@pytest.mark.skipif(
|
||||
bare or not enabled, 'https://github.com/travis-ci/apt-source-whitelist/issues/71')
|
||||
bare, reason='https://github.com/travis-ci/apt-source-whitelist/issues/71')
|
||||
@pytest.mark.parametrize('tag, dockerfile', containers)
|
||||
def test_without_confirmation(tag, dockerfile):
|
||||
with spawn(tag, dockerfile, u'fish') as proc:
|
||||
|
@ -25,6 +25,7 @@ def build_container(tag, dockerfile):
|
||||
|
||||
@contextmanager
|
||||
def spawn(tag, dockerfile, cmd):
|
||||
raise Exception([bare, enabled])
|
||||
if bare:
|
||||
proc = pexpect.spawnu(cmd)
|
||||
else:
|
||||
|
Loading…
x
Reference in New Issue
Block a user