[Git][reproducible-builds/diffoscope][master] re-order tests so that the previous does-not-exist test doesn't influence the...

Mattia Rizzolo gitlab at salsa.debian.org
Sat Jan 2 14:39:37 UTC 2021



Mattia Rizzolo pushed to branch master at Reproducible Builds / diffoscope


Commits:
f1d744da by Mattia Rizzolo at 2021-01-02T15:39:27+01:00
re-order tests so that the previous does-not-exist test doesn't influence the test_all_tools_are_listed

Signed-off-by: Mattia Rizzolo <mattia at debian.org>

- - - - -


1 changed file:

- tests/test_tools.py


Changes:

=====================================
tests/test_tools.py
=====================================
@@ -20,6 +20,20 @@ import os
 import pytest
 
 
+def test_all_tools_are_listed():
+    from diffoscope.comparators import ComparatorManager
+    from diffoscope.external_tools import EXTERNAL_TOOLS
+    from diffoscope.tools import tool_required
+
+    ComparatorManager().reload()
+
+    tools = set(tool_required.all)
+
+    for x in tools:
+        if x not in EXTERNAL_TOOLS:
+            pytest.fail(f"{x} is not present in EXTERNAL_TOOLS")
+
+
 def test_sbin_added_to_path():
     from diffoscope.tools import tool_required
 
@@ -42,17 +56,3 @@ def test_required_tool_not_found():
 
     with pytest.raises(RequiredToolNotFound):
         fn()
-
-
-def test_all_tools_are_listed():
-    from diffoscope.comparators import ComparatorManager
-    from diffoscope.external_tools import EXTERNAL_TOOLS
-    from diffoscope.tools import tool_required
-
-    ComparatorManager().reload()
-
-    tools = set(tool_required.all)
-
-    for x in tools:
-        if x not in EXTERNAL_TOOLS:
-            pytest.fail(f"{x} is not present in EXTERNAL_TOOLS")



View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/-/commit/f1d744da16feedfe4bb87462605ed2f0dbd58f69

-- 
View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/-/commit/f1d744da16feedfe4bb87462605ed2f0dbd58f69
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.reproducible-builds.org/pipermail/rb-commits/attachments/20210102/27d62d8a/attachment.htm>


More information about the rb-commits mailing list