This is an automated email from the ASF dual-hosted git repository.
tvalentyn pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git
The following commit(s) were added to refs/heads/master by this push:
new f676d93030c When comparing Series, sort the values in Dataframe tests
(#28557)
f676d93030c is described below
commit f676d93030cf9d0c849337f1e3a4efff1d8f2509
Author: caneff <[email protected]>
AuthorDate: Wed Sep 20 12:34:41 2023 -0400
When comparing Series, sort the values in Dataframe tests (#28557)
---
sdks/python/apache_beam/dataframe/frames_test.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/sdks/python/apache_beam/dataframe/frames_test.py
b/sdks/python/apache_beam/dataframe/frames_test.py
index 4998683461b..30d99248051 100644
--- a/sdks/python/apache_beam/dataframe/frames_test.py
+++ b/sdks/python/apache_beam/dataframe/frames_test.py
@@ -193,6 +193,9 @@ class _AbstractFrameTest(unittest.TestCase):
if expected.index.is_unique:
expected = expected.sort_index()
actual = actual.sort_index()
+ elif isinstance(expected, pd.Series):
+ expected = expected.sort_values()
+ actual = actual.sort_values()
else:
expected = expected.sort_values(list(expected.columns))
actual = actual.sort_values(list(actual.columns))