kopia lustrzana https://github.com/jupyterhub/repo2docker
Move test fixture to conftest.py
rodzic
871b0629a4
commit
754edd01c4
|
@ -68,6 +68,14 @@ def make_test_func(args):
|
|||
return test
|
||||
|
||||
|
||||
@pytest.fixture()
|
||||
def run_repo2docker():
|
||||
def run_test(args):
|
||||
return make_test_func(args)()
|
||||
return run_test
|
||||
|
||||
|
||||
|
||||
class Repo2DockerTest(pytest.Function):
|
||||
"""A pytest.Item for running repo2docker"""
|
||||
def __init__(self, name, parent, args):
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
import pytest
|
||||
import os
|
||||
import time
|
||||
import re
|
||||
|
@ -10,13 +9,6 @@ from repo2docker.app import Repo2Docker
|
|||
DIR = os.path.join(os.path.dirname(__file__), 'dockerfile', 'editable')
|
||||
|
||||
|
||||
@pytest.fixture(scope="module")
|
||||
def run_repo2docker():
|
||||
def run_test(args):
|
||||
return make_test_func(args)()
|
||||
return run_test
|
||||
|
||||
|
||||
def test_editable(run_repo2docker):
|
||||
"""Run a local repository in edit mode. Verify a new file has been
|
||||
created afterwards"""
|
||||
|
|
Ładowanie…
Reference in New Issue