Skip to content

Commit 800cd00

Browse files
ZzEeKkAaDiptorup Deb
authored andcommitted
Port print tests
1 parent ac5e4e6 commit 800cd00

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

numba_dpex/tests/kernel_tests/test_print.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
import dpctl
66
import dpnp
77
import pytest
8-
from numba.core.errors import LoweringError
8+
from numba.core.errors import TypingError
99

10-
import numba_dpex as dpex
10+
import numba_dpex.experimental as dpex
1111

1212
list_of_dtypes = [
1313
dpnp.int32,
@@ -84,9 +84,11 @@ def print_string(a):
8484

8585
a = input_arrays
8686

87-
with pytest.raises(LoweringError):
87+
with pytest.raises(TypingError) as ex_info:
8888
dpex.call_kernel(print_string, dpex.Range(1), a)
8989

90+
assert "LoweringError" in ex_info.value.args[0]
91+
9092

9193
@skip_on_gpu
9294
def test_print_array(input_arrays):
@@ -100,5 +102,7 @@ def print_string(a):
100102

101103
a = input_arrays
102104

103-
with pytest.raises(LoweringError):
105+
with pytest.raises(TypingError) as ex_info:
104106
dpex.call_kernel(print_string, dpex.Range(1), a)
107+
108+
assert "LoweringError" in ex_info.value.args[0]

0 commit comments

Comments
 (0)