Skip to content

Commit ebee631

Browse files
committed
Update pytest exception types
1 parent 5818e31 commit ebee631

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

python/test/unit/fem/test_forms.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,13 +47,13 @@ def test_extract_forms():
4747
v3, u3 = TestFunction(V3), TrialFunction(V3)
4848

4949
a = form([[inner(u0, v0) * dx, inner(u1, v1) * dx], [inner(u2, v2) * dx, inner(u3, v3) * dx]])
50-
with pytest.raises(AssertionError):
50+
with pytest.raises(ValueError):
5151
extract_function_spaces(a, 0)
52-
with pytest.raises(AssertionError):
52+
with pytest.raises(ValueError):
5353
extract_function_spaces(a, 1)
5454

5555
a = form([[inner(u0, v0) * dx, inner(u2, v1) * dx], [inner(u0, v2) * dx, inner(u2, v2) * dx]])
56-
with pytest.raises(AssertionError):
56+
with pytest.raises(ValueError):
5757
extract_function_spaces(a, 0)
5858
Vc = extract_function_spaces(a, 1)
5959
assert Vc[0] is V0._cpp_object
@@ -63,7 +63,7 @@ def test_extract_forms():
6363
Vr = extract_function_spaces(a, 0)
6464
assert Vr[0] is V0._cpp_object
6565
assert Vr[1] is V1._cpp_object
66-
with pytest.raises(AssertionError):
66+
with pytest.raises(ValueError):
6767
extract_function_spaces(a, 1)
6868

6969

0 commit comments

Comments
 (0)