aboutsummaryrefslogtreecommitdiff
path: root/tests/unit/computations
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/computations')
-rw-r--r--tests/unit/computations/data/correlation/sorted_results.txt10
-rw-r--r--tests/unit/computations/test_rust_correlation.py16
2 files changed, 14 insertions, 12 deletions
diff --git a/tests/unit/computations/data/correlation/sorted_results.txt b/tests/unit/computations/data/correlation/sorted_results.txt
index f171f5a..57885b5 100644
--- a/tests/unit/computations/data/correlation/sorted_results.txt
+++ b/tests/unit/computations/data/correlation/sorted_results.txt
@@ -1,5 +1,5 @@
-63.62,0.97,0.00
-19,-0.96,0.22
-77.92,-0.94,0.31
-84.04,0.94,0.11
-23,-0.91,0.11 \ No newline at end of file
+63.62,0.97,0.00,12
+19,-0.96,0.22,12
+77.92,-0.94,0.31,12
+84.04,0.94,0.11,12
+23,-0.91,0.11,12 \ No newline at end of file
diff --git a/tests/unit/computations/test_rust_correlation.py b/tests/unit/computations/test_rust_correlation.py
index 0fd8e94..d5a6eb7 100644
--- a/tests/unit/computations/test_rust_correlation.py
+++ b/tests/unit/computations/test_rust_correlation.py
@@ -57,16 +57,18 @@ def test_parse_results():
"""test for parsing file results"""
raw_data = [
- ["63.62", "0.97", "0.00"],
- ["19", "-0.96", "0.22"],
- ["77.92", "-0.94", "0.31"],
- ["84.04", "0.94", "0.11"],
- ["23", "-0.91", "0.11"]
+ ["63.62", "0.97", "0.00", "12"],
+ ["19", "-0.96", "0.22", "12"],
+ ["77.92", "-0.94", "0.31", "12"],
+ ["84.04", "0.94", "0.11", "12"],
+ ["23", "-0.91", "0.11", "12"]
]
raw_dict = [{trait: {
- "num_overlap": 00,
- "p_value": p_val}} for (trait, corr_coeff, p_val) in raw_data]
+ "num_overlap": num_overlap,
+ "corr_coefficient": corr_coeff,
+ "p_value": p_val}} for (trait, corr_coeff,
+ p_val, num_overlap) in raw_data]
assert (parse_correlation_output(
"tests/unit/computations/data/correlation/sorted_results.txt",