Skip to content
This repository was archived by the owner on Feb 2, 2024. It is now read-only.

Commit c5004bc

Browse files
committed
Skip tests in test_strings using @skip_numba_jit
1 parent b60774d commit c5004bc

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

sdc/tests/test_strings.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
from sdc.str_arr_ext import StringArray
4040
from sdc.str_ext import unicode_to_std_str, std_str_to_unicode
4141
from sdc.tests.gen_test_data import ParquetGenerator
42-
from sdc.tests.test_utils import TestCase
42+
from sdc.tests.test_utils import skip_numba_jit, TestCase
4343

4444
class TestStrings(TestCase):
4545

@@ -62,6 +62,7 @@ def test_impl():
6262
hpat_func = sdc.jit(test_impl)
6363
self.assertEqual(hpat_func(), test_impl())
6464

65+
@skip_numba_jit
6566
def test_str2str(self):
6667
str2str_methods = ['capitalize', 'casefold', 'lower', 'lstrip',
6768
'rstrip', 'strip', 'swapcase', 'title', 'upper']
@@ -212,6 +213,7 @@ def test_impl():
212213

213214
self.assertTrue(np.array_equal(hpat_func(), ['ABC', 'BB', 'CDEF']))
214215

216+
@skip_numba_jit
215217
def test_string_array_comp(self):
216218
def test_impl():
217219
A = StringArray(['ABC', 'BB', 'CDEF'])
@@ -221,6 +223,7 @@ def test_impl():
221223

222224
self.assertEqual(hpat_func(), 1)
223225

226+
@skip_numba_jit
224227
def test_string_series(self):
225228
def test_impl(ds):
226229
rs = ds == 'one'
@@ -238,6 +241,7 @@ def test_impl(ds):
238241
self.assertTrue(isinstance(ds, pd.Series) and isinstance(rs, pd.Series))
239242
self.assertTrue(ds[0] == 'one' and ds[2] == 'three' and rs[0] and not rs[2])
240243

244+
@skip_numba_jit
241245
def test_string_array_bool_getitem(self):
242246
def test_impl():
243247
A = StringArray(['ABC', 'BB', 'CDEF'])
@@ -248,6 +252,7 @@ def test_impl():
248252

249253
self.assertEqual(hpat_func(), True)
250254

255+
@skip_numba_jit
251256
def test_string_NA_box(self):
252257
# create `example.parquet` file
253258
ParquetGenerator.gen_pq_test()
@@ -262,6 +267,7 @@ def test_impl():
262267
np.testing.assert_array_equal(hpat_func().isna(), test_impl().isna())
263268

264269
# test utf8 decode
270+
@skip_numba_jit
265271
def test_decode_empty1(self):
266272
def test_impl(S):
267273
return S[0]
@@ -270,6 +276,7 @@ def test_impl(S):
270276
S = pd.Series([''])
271277
self.assertEqual(hpat_func(S), test_impl(S))
272278

279+
@skip_numba_jit
273280
def test_decode_single_ascii_char1(self):
274281
def test_impl(S):
275282
return S[0]
@@ -278,6 +285,7 @@ def test_impl(S):
278285
S = pd.Series(['A'])
279286
self.assertEqual(hpat_func(S), test_impl(S))
280287

288+
@skip_numba_jit
281289
def test_decode_ascii1(self):
282290
def test_impl(S):
283291
return S[0]
@@ -286,6 +294,7 @@ def test_impl(S):
286294
S = pd.Series(['Abc12', 'bcd', '345'])
287295
self.assertEqual(hpat_func(S), test_impl(S))
288296

297+
@skip_numba_jit
289298
def test_decode_unicode1(self):
290299
def test_impl(S):
291300
return S[0], S[1], S[2]
@@ -295,6 +304,7 @@ def test_impl(S):
295304
'🐍⚡', '大处着眼,小处着手。', ])
296305
self.assertEqual(hpat_func(S), test_impl(S))
297306

307+
@skip_numba_jit
298308
def test_decode_unicode2(self):
299309
# test strings that start with ascii
300310
def test_impl(S):

0 commit comments

Comments
 (0)