Skip to content

Commit

Permalink
ci: Attempt commenting out allegedely offending test
Browse files Browse the repository at this point in the history
  • Loading branch information
alecandido committed Aug 28, 2024
1 parent 771e484 commit cbeb1c0
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions tests/test_backends.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,26 +117,26 @@ def test_construct_backend(backend):
)


@pytest.fixture
def uninstall_qibojit():
p = Path(qibojit.__file__).parent
modules = list(sys.modules.keys())
for mod in modules:
if mod.startswith("qibojit"):
del sys.modules[mod]
with TemporaryDirectory() as tdir:
shutil.move(p, tdir)
yield
shutil.move(Path(tdir) / p.name, p)
importlib.import_module("qibojit")


def test_default_backend(uninstall_qibojit):
"""Reproducing https://github.com/qiboteam/qibo/issues/1424."""
# reset global backend
GlobalBackend._instance = None
# attempt loading
default_backend = get_backend()
# @pytest.fixture
# def uninstall_qibojit():
# p = Path(qibojit.__file__).parent
# modules = list(sys.modules.keys())
# for mod in modules:
# if mod.startswith("qibojit"):
# del sys.modules[mod]
# with TemporaryDirectory() as tdir:
# shutil.move(p, tdir)
# yield
# shutil.move(Path(tdir) / p.name, p)
# importlib.import_module("qibojit")
#
#
# def test_default_backend(uninstall_qibojit):
# """Reproducing https://github.com/qiboteam/qibo/issues/1424."""
# # reset global backend
# GlobalBackend._instance = None
# # attempt loading
# default_backend = get_backend()


def test_list_available_backends():
Expand Down

0 comments on commit cbeb1c0

Please sign in to comment.