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

Commit

Permalink
Merge 91e8caf into 5b91644
Browse files Browse the repository at this point in the history
  • Loading branch information
shssf committed Oct 26, 2019
2 parents 5b91644 + 91e8caf commit a7381a2
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions hpat/tests/test_series.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# -*- coding: utf-8 -*-

import unittest
import platform
import pandas as pd
Expand Down Expand Up @@ -104,6 +106,48 @@ def test_impl():

self.assertEqual(hpat_func(), test_impl())

@unittest.skip('Feature request: implement Series::ctor with list(list(type))')
def test_create_list_list_unicode(self):
def test_impl():
S = pd.Series([
[ 'abc', 'defg', 'ijk'],
[ 'lmn', 'opq', 'rstuvwxyz']
])
return S
hpat_func = hpat.jit(test_impl)

result_ref = test_impl()
result = hpat_func()
pd.testing.assert_series_equal(result, result_ref)

@unittest.skip('Feature request: implement Series::ctor with list(list(type))')
def test_create_list_list_integer(self):
def test_impl():
S = pd.Series([
[ 123, 456, -789],
[ -112233, 445566, 778899]
])
return S
hpat_func = hpat.jit(test_impl)

result_ref = test_impl()
result = hpat_func()
pd.testing.assert_series_equal(result, result_ref)

@unittest.skip('Feature request: implement Series::ctor with list(list(type))')
def test_create_list_list_float(self):
def test_impl():
S = pd.Series([
[ 1.23, -4.56, 7.89],
[ 11.2233, 44.5566, -778.899]
])
return S
hpat_func = hpat.jit(test_impl)

result_ref = test_impl()
result = hpat_func()
pd.testing.assert_series_equal(result, result_ref)

def test_create2(self):
def test_impl(n):
df = pd.DataFrame({'A': np.arange(n)})
Expand Down

0 comments on commit a7381a2

Please sign in to comment.