Commit be211dd2 authored by Alex Lubbock's avatar Alex Lubbock

Move unit test to appropriate location

parent 2e72088e
...@@ -60,6 +60,14 @@ class TestInline(CythonTest): ...@@ -60,6 +60,14 @@ class TestInline(CythonTest):
""", a=3, **self.test_kwds) """, a=3, **self.test_kwds)
self.assertEquals(type(b), float) self.assertEquals(type(b), float)
def test_compiler_directives(self):
self.assertEqual(
inline('return sum(x)',
x=[1, 2, 3],
cython_compiler_directives={'boundscheck': False}),
6
)
if has_numpy: if has_numpy:
def test_numpy(self): def test_numpy(self):
......
...@@ -849,14 +849,6 @@ f'{a * x()}'""" ...@@ -849,14 +849,6 @@ f'{a * x()}'"""
self.assertEqual(f'{d["foo"]}', 'bar') self.assertEqual(f'{d["foo"]}', 'bar')
self.assertEqual(f"{d['foo']}", 'bar') self.assertEqual(f"{d['foo']}", 'bar')
def test_inline_compiler_directives(self):
self.assertEqual(
cy_eval('sum(x)',
x=[1,2,3],
cython_compiler_directives={'boundscheck': False}),
6
)
def __test_backslash_char(self): def __test_backslash_char(self):
# Check eval of a backslash followed by a control char. # Check eval of a backslash followed by a control char.
# See bpo-30682: this used to raise an assert in pydebug mode. # See bpo-30682: this used to raise an assert in pydebug mode.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment