Skip to content

Commit

Permalink
Make all fixtures session-scoped (they should be)
Browse files Browse the repository at this point in the history
  • Loading branch information
tkf committed Sep 15, 2018
1 parent ca274b1 commit 991ccb3
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/ipython_jl/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from .. import ipyext


@pytest.fixture
@pytest.fixture(scope="session")
def Main():
""" pytest fixture for providing a Julia `Main` name space. """
if core._Main is None:
Expand All @@ -13,15 +13,14 @@ def Main():
return core._Main


@pytest.fixture
@pytest.fixture(scope="session")
def julia(Main):
""" pytest fixture for providing a `JuliaAPI` instance. """
return core.get_api(Main)


@pytest.fixture(scope="session")
def ipy_with_magic():
Main() # check if Julia API is ready
def ipy_with_magic(Main):
from IPython.testing.globalipapp import get_ipython
ip = get_ipython()
ipyext.load_ipython_extension(ip)
Expand Down

0 comments on commit 991ccb3

Please sign in to comment.