Skip to content

Commit

Permalink
codestyle
Browse files Browse the repository at this point in the history
  • Loading branch information
mbeisel committed Jan 8, 2024
1 parent b041a8e commit 43bc450
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 13 deletions.
25 changes: 14 additions & 11 deletions tests/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,13 @@ def test_cm_noisy_simulator(self):
self.assertTrue(".pkl" in response.json)

response_get = self.client.get(
"/cm/?noise_model=" + backend +
"&cm_gen_method=" + "standard" +
"&qpu=aer_qasm_simulator" +
"&qubits=0&qubits=1&qubits=2&qubits=3&qubits=4"+
"&max_age=360"
"/cm/?noise_model="
+ backend
+ "&cm_gen_method="
+ "standard"
+ "&qpu=aer_qasm_simulator"
+ "&qubits=0&qubits=1&qubits=2&qubits=3&qubits=4"
+ "&max_age=360"
)
self.assertEqual(response_get.status_code, 200)
self.assertEqual(len(response_get.json), 32)
Expand Down Expand Up @@ -191,12 +193,13 @@ def test_mm_noisy_simulator_only_measure(self):
self.assertTrue(".pkl" in response.json)

response_get = self.client.get(
"/mm/?noise_model=" + backend +
"&cm_gen_method=standard" +
"&mitigation_method=inversion" +
"&qpu=aer_qasm_simulator" +
"&qubits=0&qubits=1&qubits=2&qubits=3&qubits=4"+
"&max_age=360"
"/mm/?noise_model="
+ backend
+ "&cm_gen_method=standard"
+ "&mitigation_method=inversion"
+ "&qpu=aer_qasm_simulator"
+ "&qubits=0&qubits=1&qubits=2&qubits=3&qubits=4"
+ "&max_age=360"
)
self.assertEqual(response_get.status_code, 200)
self.assertEqual(len(response_get.json), 32)
Expand Down
5 changes: 3 additions & 2 deletions tests/utils_test.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
from qiskit_ibm_provider import IBMProvider


def get_available_qpu(credentials):
provider = IBMProvider(**credentials)
backends = provider.backends()
for backend in backends:
if 'simulator' not in backend.name:
return backend.name
if "simulator" not in backend.name:
return backend.name

0 comments on commit 43bc450

Please sign in to comment.