Skip to content
Snippets Groups Projects

Clean up and Bug Fixes

Merged Markus Holzer requested to merge holzer/pystencils:Fixes into master
Compare and Show latest version
3 files
+ 7
7
Preferences
Compare changes
Files
3
@@ -5,7 +5,6 @@ import numpy as np
# This test aims to trigger deprication warnings. Thus the warnings should not be displayed in the warning summary.
@pytest.mark.filterwarnings("ignore::DeprecationWarning")
def test_create_kernel_backwards_compatibility():
size = (30, 20)
@@ -21,9 +20,11 @@ def test_create_kernel_backwards_compatibility():
jacobi = ps.Assignment(d[0, 0], (f[1, 0] + f[-1, 0] + f[0, 1] + f[0, -1]) / 4)
ast_enum = ps.create_kernel(jacobi, target=ps.Target.CPU).compile()
ast_string = ps.create_kernel(jacobi, target='cpu').compile()
with pytest.warns(DeprecationWarning):
ast_string = ps.create_kernel(jacobi, target='cpu').compile()
# noinspection PyTypeChecker
ast_config = ps.create_kernel(jacobi, config=ps.CreateKernelConfig(target='cpu')).compile()
with pytest.warns(DeprecationWarning):
ast_config = ps.create_kernel(jacobi, config=ps.CreateKernelConfig(target='cpu')).compile()
ast_enum(f=src_field_enum, d=dst_field_enum)
ast_string(f=src_field_string, d=dst_field_string)
ast_config(f=src_field_config, d=dst_field_config)