This is an automated email from the ASF dual-hosted git repository.

dongjoon pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git


The following commit(s) were added to refs/heads/master by this push:
     new 6c486d2  [SPARK-38436][PYTHON][TESTS] Fix `test_ceil` to test `ceil`
6c486d2 is described below

commit 6c486d2eba5750b502468cd837b0ccdca849cc21
Author: Bjørn Jørgensen <[email protected]>
AuthorDate: Mon Mar 7 11:01:32 2022 -0800

    [SPARK-38436][PYTHON][TESTS] Fix `test_ceil` to test `ceil`
    
    ### What changes were proposed in this pull request?
    We have two functions that are testing the same thing.
    
    ### Why are the changes needed?
    To test both floor and ceil.
    
    ### Does this PR introduce _any_ user-facing change?
    No.
    
    ### How was this patch tested?
    Got the green light.
    
    Closes #35755 from bjornjorgensen/Test-ceil.
    
    Authored-by: Bjørn Jørgensen <[email protected]>
    Signed-off-by: Dongjoon Hyun <[email protected]>
---
 python/pyspark/pandas/tests/test_series_datetime.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/python/pyspark/pandas/tests/test_series_datetime.py 
b/python/pyspark/pandas/tests/test_series_datetime.py
index 637c189..d837c34 100644
--- a/python/pyspark/pandas/tests/test_series_datetime.py
+++ b/python/pyspark/pandas/tests/test_series_datetime.py
@@ -264,8 +264,8 @@ class SeriesDateTimeTest(PandasOnSparkTestCase, 
SQLTestUtils):
         self.check_func(lambda x: x.dt.floor(freq="H"))
 
     def test_ceil(self):
-        self.check_func(lambda x: x.dt.floor(freq="min"))
-        self.check_func(lambda x: x.dt.floor(freq="H"))
+        self.check_func(lambda x: x.dt.ceil(freq="min"))
+        self.check_func(lambda x: x.dt.ceil(freq="H"))
 
     @unittest.skip("Unsupported locale setting")
     def test_month_name(self):

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to