diff --git a/tests/test_apply.py b/tests/test_apply.py index 1b9b02a..e8debff 100755 --- a/tests/test_apply.py +++ b/tests/test_apply.py @@ -294,12 +294,12 @@ def test_apply_errors_basis_state(self): dev = QulacsDevice(1) with pytest.raises( - ValueError, match="BasisState parameter must consist of 0 or 1 integers." + ValueError, match="Basis state must only consist of 0s and 1s" ): dev.apply([qml.BasisState(np.array([-0.2, 4.2]), wires=[0, 1])]) with pytest.raises( - ValueError, match="BasisState parameter and wires must be of equal length." + ValueError, match="State must be of length 1; got length 2" ): dev.apply([qml.BasisState(np.array([0, 1]), wires=[0])])