Skip to content

Commit

Permalink
Fix global tqdm module patch in test (#2319)
Browse files Browse the repository at this point in the history
  • Loading branch information
cosenal authored Apr 29, 2024
1 parent a134e52 commit b7b6e1e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mitiq/shadows/tests/test_quantum_processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ def test_tqdm_import_not_available():
) # Reload the module to trigger the import
assert mitiq.shadows.quantum_processing.tqdm is None

# Reload the module again to restore the original tqdm import.
# Otherwise, the rest of the tests are affected by the patch (issue #2318)
importlib.reload(mitiq.shadows.quantum_processing)


def test_generate_random_pauli_strings():
"""Tests that the function generates random Pauli strings."""
Expand Down

0 comments on commit b7b6e1e

Please sign in to comment.