Skip to content

Commit 79d0ff2

Browse files
committed
update test
1 parent 4d87a34 commit 79d0ff2

File tree

1 file changed

+8
-12
lines changed

1 file changed

+8
-12
lines changed

tests/callback/test_callback.py

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -76,13 +76,13 @@ def test_pipeline_callbacks():
7676

7777
assert len(dummy_callback.history) == 23
7878
assert dummy_callback.history[0][0] == "start_run"
79-
assert dummy_callback.history[0][1].keys() == {"run_name"}
79+
assert "run_name" in dummy_callback.history[0][1]
8080
assert dummy_callback.history[1:] == [
8181
(
8282
"start_module",
8383
{
8484
"module_name": "retrieval",
85-
"j_combination": 0,
85+
"num": 0,
8686
"module_kwargs": {"k": 5, "embedder_name": "sergeyzh/rubert-tiny-turbo"},
8787
},
8888
),
@@ -92,7 +92,7 @@ def test_pipeline_callbacks():
9292
"start_module",
9393
{
9494
"module_name": "retrieval",
95-
"j_combination": 1,
95+
"num": 1,
9696
"module_kwargs": {"k": 10, "embedder_name": "sergeyzh/rubert-tiny-turbo"},
9797
},
9898
),
@@ -102,7 +102,7 @@ def test_pipeline_callbacks():
102102
"start_module",
103103
{
104104
"module_name": "knn",
105-
"j_combination": 0,
105+
"num": 0,
106106
"module_kwargs": {"k": 1, "weights": "uniform", "embedder_name": "sergeyzh/rubert-tiny-turbo"},
107107
},
108108
),
@@ -112,26 +112,22 @@ def test_pipeline_callbacks():
112112
"start_module",
113113
{
114114
"module_name": "knn",
115-
"j_combination": 1,
115+
"num": 1,
116116
"module_kwargs": {"k": 1, "weights": "distance", "embedder_name": "sergeyzh/rubert-tiny-turbo"},
117117
},
118118
),
119119
("log_value", {"scoring_roc_auc": np.float64(1.0)}),
120120
("end_module", {}),
121121
(
122122
"start_module",
123-
{
124-
"module_name": "linear",
125-
"j_combination": 0,
126-
"module_kwargs": {"embedder_name": "sergeyzh/rubert-tiny-turbo"},
127-
},
123+
{"module_name": "linear", "num": 0, "module_kwargs": {"embedder_name": "sergeyzh/rubert-tiny-turbo"}},
128124
),
129125
("log_value", {"scoring_roc_auc": np.float64(1.0)}),
130126
("end_module", {}),
131-
("start_module", {"module_name": "threshold", "j_combination": 0, "module_kwargs": {"thresh": 0.5}}),
127+
("start_module", {"module_name": "threshold", "num": 0, "module_kwargs": {"thresh": 0.5}}),
132128
("log_value", {"decision_accuracy": np.float64(0.75)}),
133129
("end_module", {}),
134-
("start_module", {"module_name": "argmax", "j_combination": 0, "module_kwargs": {}}),
130+
("start_module", {"module_name": "argmax", "num": 0, "module_kwargs": {}}),
135131
("log_value", {"decision_accuracy": np.float64(0.75)}),
136132
("end_module", {}),
137133
("end_run", {}),

0 commit comments

Comments
 (0)