Skip to content

Commit

Permalink
Fixed conflicts, added test for timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
NischalQuTech committed Oct 22, 2024
1 parent 118ea31 commit 24d30bc
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions tests/test_qi_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from pytest_mock import MockerFixture
from qiskit import QuantumCircuit, qpy
from qiskit.providers import BackendV2
from qiskit.providers.exceptions import JobTimeoutError
from qiskit.providers.jobstatus import JobStatus
from qiskit.qobj import QobjExperimentHeader
from qiskit.result.models import ExperimentResult, ExperimentResultData
Expand All @@ -18,7 +19,6 @@
from qiskit_quantuminspire.qi_backend import QIBackend
from qiskit_quantuminspire.qi_jobs import QIJob
from tests.helpers import create_backend_type
from qiskit.providers.exceptions import JobTimeoutError


class SingleBackendProvider(BaseProvider):
Expand Down Expand Up @@ -103,9 +103,7 @@ def test_result_blocking_timeout(mocker: MockerFixture) -> None:


@pytest.mark.asyncio
def test_result_non_blocking(
mocker: MockerFixture, mock_api_client: MagicMock, mock_batchjob_api: MagicMock
) -> None:
def test_result_non_blocking(mocker: MockerFixture, mock_api_client: MagicMock, mock_batchjob_api: MagicMock) -> None:
job = QIJob(run_input="", backend=None)
mocker.patch.object(job, "done", return_value=False)
mock_wait_for_final_state = mocker.patch.object(job, "wait_for_final_state", return_value=None)
Expand Down

0 comments on commit 24d30bc

Please sign in to comment.