From df6e4ab055fedfc8201c02d420aa8ef1072c76df Mon Sep 17 00:00:00 2001 From: Raphael Mitsch Date: Mon, 12 Dec 2022 14:05:41 +0100 Subject: [PATCH] Reformat EL test. --- spacy/tests/pipeline/test_entity_linker.py | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/spacy/tests/pipeline/test_entity_linker.py b/spacy/tests/pipeline/test_entity_linker.py index c6030be41..2f30672c1 100644 --- a/spacy/tests/pipeline/test_entity_linker.py +++ b/spacy/tests/pipeline/test_entity_linker.py @@ -1200,16 +1200,9 @@ def test_threshold(meet_threshold: bool, config: Dict[str, Any]): "entity_linker", last=True, config={ - **( - {"threshold": None} - if meet_threshold - else { - "threshold": 1.0, - # Prior for candidate may be 1.0, rendering the our test setting with threshold 1.0 useless - # otherwise. - "incl_prior": False, - } - ), + "threshold": None if meet_threshold else 1.0, + # Prior for candidate may be 1.0, rendering the our test setting with threshold 1.0 useless otherwise. + "incl_prior": meet_threshold, "model": config, }, )