You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by be...@apache.org on 2023/08/11 00:17:16 UTC

[superset] branch sc_73447 updated: Update test

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

beto pushed a commit to branch sc_73447
in repository https://gitbox.apache.org/repos/asf/superset.git


The following commit(s) were added to refs/heads/sc_73447 by this push:
     new 357b7962a1 Update test
357b7962a1 is described below

commit 357b7962a1e81319cd0c2aeb32badc8d1fe74a8a
Author: Beto Dealmeida <ro...@dealmeida.net>
AuthorDate: Thu Aug 10 17:15:30 2023 -0700

    Update test
---
 tests/integration_tests/utils_tests.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tests/integration_tests/utils_tests.py b/tests/integration_tests/utils_tests.py
index c0383d1d0b..86d8bf6e68 100644
--- a/tests/integration_tests/utils_tests.py
+++ b/tests/integration_tests/utils_tests.py
@@ -1114,7 +1114,7 @@ class TestUtils(SupersetTestCase):
         df = pd.DataFrame([{"__timestamp": ts.timestamp() * 1000, "a": 1}])
         assert normalize_col(df, "epoch_ms", 0, None)[DTTM_ALIAS][0] == ts
 
-        # test that out of bounds timestamps are coerced to None instead of
-        # erroring out
+        # test that we raise an error when we can't convert
         df = pd.DataFrame([{"__timestamp": "1677-09-21 00:00:00", "a": 1}])
-        assert pd.isnull(normalize_col(df, None, 0, None)[DTTM_ALIAS][0])
+        with pytest.raises(pd.errors.OutOfBoundsDatetime):
+            normalize_col(df, None, 0, None)