Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
renatomello committed Mar 14, 2024
1 parent 8283cb8 commit 8208831
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions tests/test_transpiler_router.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ def test_sabre_random_circuits(n_gates, look, decay, placer, connectivity):
final_map=final_qubit_map,
initial_map=initial_layout,
)
assert transpiled_circuit.queue[-1].result is measurement.result
assert transpiled_circuit.queue[-1].register_name == measurement.register_name


def test_sabre_memory_map():
Expand All @@ -322,9 +322,8 @@ def test_sabre_intermediate_measurements():
connectivity.add_edges_from([(0, 1), (1, 2)])
router = Sabre(connectivity=connectivity)
initial_layout = {"q0": 0, "q1": 1, "q2": 2}
routed_circ, final_layout = router(circuit=circ, initial_layout=initial_layout)
circuit_result = routed_circ.execute(nshots=100)
assert routed_circ.queue[3].result is measurement.result
routed_circ, _ = router(circuit=circ, initial_layout=initial_layout)
assert routed_circ.queue[3].register_name == measurement.register_name


@pytest.mark.parametrize("router_algorithm", [Sabre, ShortestPaths])
Expand Down

0 comments on commit 8208831

Please sign in to comment.