From 3cbde49e5808400db852b2b7ddb3d6826a1e32b8 Mon Sep 17 00:00:00 2001 From: Winston Chang Date: Wed, 24 Jul 2024 15:54:09 -0500 Subject: [PATCH] Use 'is None' instead of '== None' --- tests/test_deps.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_deps.py b/tests/test_deps.py index 18a79ee..8725271 100644 --- a/tests/test_deps.py +++ b/tests/test_deps.py @@ -40,7 +40,7 @@ def test_module_to_package_key(): assert module_to_package_key("cv2") == "opencv-python" assert module_to_package_key("black") == "black" - assert module_to_package_key("foobar") == None + assert module_to_package_key("foobar") is None def test_dep_name_to_dep_key(): @@ -54,13 +54,13 @@ def test_dep_name_to_dep_key(): ) # Should not convert `_` to `-` - assert dep_name_to_dep_key("typing_extensions") == None + assert dep_name_to_dep_key("typing_extensions") is None # Should be case insensitive to input. assert dep_name_to_dep_key("Jinja2") == "jinja2" assert dep_name_to_dep_key("JiNJa2") == "jinja2" - assert dep_name_to_dep_key("cv2") == None + assert dep_name_to_dep_key("cv2") is None def test_find_recursive_deps():