From 4ad560471194eca569c32d6b3052aa74b8d42e77 Mon Sep 17 00:00:00 2001 From: "Joran R. Angevaare" Date: Wed, 30 Mar 2022 14:23:33 +0200 Subject: [PATCH 1/3] Up utils coverage --- tests/test_utils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/test_utils.py b/tests/test_utils.py index 9e48ad57..47f741ff 100644 --- a/tests/test_utils.py +++ b/tests/test_utils.py @@ -24,3 +24,4 @@ def test_to_str_tuple(): def test_get_hash(): dddm.utils.deterministic_hash({'bla': np.zeros(19), 'foo': pd.DataFrame()}) + dddm.utils.deterministic_hash(np.arange(19)) From 0c78cfe23a1dae47e85777ccc378b59b3e859fe4 Mon Sep 17 00:00:00 2001 From: "Joran R. Angevaare" Date: Wed, 30 Mar 2022 14:34:49 +0200 Subject: [PATCH 2/3] Update test_utils.py --- tests/test_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_utils.py b/tests/test_utils.py index 47f741ff..b0521745 100644 --- a/tests/test_utils.py +++ b/tests/test_utils.py @@ -24,4 +24,4 @@ def test_to_str_tuple(): def test_get_hash(): dddm.utils.deterministic_hash({'bla': np.zeros(19), 'foo': pd.DataFrame()}) - dddm.utils.deterministic_hash(np.arange(19)) + dddm.utils.deterministic_hash(list(np.arange(19, dtype=np.int64))) From 02357f17c1d8484f370a02339cbc529d8eddaa82 Mon Sep 17 00:00:00 2001 From: "Joran R. Angevaare" Date: Wed, 30 Mar 2022 14:47:40 +0200 Subject: [PATCH 3/3] Update test_utils.py --- tests/test_utils.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/test_utils.py b/tests/test_utils.py index b0521745..0dbfa268 100644 --- a/tests/test_utils.py +++ b/tests/test_utils.py @@ -25,3 +25,8 @@ def test_get_hash(): dddm.utils.deterministic_hash({'bla': np.zeros(19), 'foo': pd.DataFrame()}) dddm.utils.deterministic_hash(list(np.arange(19, dtype=np.int64))) + dddm.utils.deterministic_hash( + list(np.arange(3, dtype=np.int64)) + + [{str(a): a for a in np.arange(3, dtype=np.float64)}] + + [np.array([np.arange(2), np.arange(2)])] + )