Skip to content

Commit

Permalink
fix test following review
Browse files Browse the repository at this point in the history
  • Loading branch information
ShellyGarion committed Sep 5, 2022
1 parent 4e386b4 commit de83cbe
Showing 1 changed file with 5 additions and 21 deletions.
26 changes: 5 additions & 21 deletions test/python/quantum_info/operators/test_dihedral.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,27 +45,11 @@ def random_cnotdihedral_circuit(num_qubits, num_gates, gates="all", seed=None):
"""Generate a pseudo random CNOTDihedral circuit."""

if gates == "all":
if num_qubits == 1:
gates = ["i", "x", "y", "z", "t", "tdg", "s", "sdg"]
elif num_qubits < 3:
gates = ["i", "x", "y", "z", "t", "tdg", "s", "sdg", "cx", "cz", "cs", "csdg", "swap"]
else:
gates = [
"i",
"x",
"y",
"z",
"t",
"tdg",
"s",
"sdg",
"cx",
"cz",
"cs",
"csdg",
"swap",
"ccz",
]
gates = ["i", "x", "y", "z", "t", "tdg", "s", "sdg"]
if num_qubits >= 2:
gates += ["cx", "cz", "cs", "csdg", "swap"]
if num_qubits >= 3:
gates += ["ccz"]

instructions = {
"i": (IGate(), 1),
Expand Down

0 comments on commit de83cbe

Please sign in to comment.