Skip to content

Commit

Permalink
Remove invalid test.
Browse files Browse the repository at this point in the history
This one I'd added thinking I ought to block store from using
a const var target. But since I figured it's better to just
restrict adding vars to the circuit that are const (and leave
the decision of whether or not a const var can be an l-value
till later), this test no longer makes sense.
  • Loading branch information
kevinhartman committed Feb 18, 2025
1 parent ccf9441 commit c6eab02
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions test/python/circuit/test_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,14 +240,6 @@ def test_rejects_non_lvalue(self):
with self.assertRaisesRegex(CircuitError, "not an l-value"):
qc.store(not_an_lvalue, expr.lift(False))

def test_rejects_const_lvalue(self):
"""At least for now, lvalue expressions with a const type are not
permitted in calls to qc.store."""
a = expr.Var.new("a", types.Bool(const=True))
qc = QuantumCircuit()
with self.assertRaisesRegex(CircuitError, "const variables.*not supported"):
qc.store(a, expr.lift(False, try_const=True))

def test_rejects_explicit_cast(self):
lvalue = expr.Var.new("a", types.Uint(16))
rvalue = expr.Var.new("b", types.Uint(8))
Expand Down

0 comments on commit c6eab02

Please sign in to comment.