]> granicus.if.org Git - graphviz/commitdiff
test_1408: don't expect failure on MinGW
authorMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Fri, 7 Jan 2022 14:58:35 +0000 (15:58 +0100)
committerMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Mon, 10 Jan 2022 08:35:28 +0000 (09:35 +0100)
It's unclear why this test does not fail on MinGW when if fails on
other OSes. The NDEBUG symbols is not defined in MinGW builds and
assertions have been verified to be enabled.

rtest/test_regression.py

index 5cde878714aaf0bb9910989b404dae09169ad72c..4f3e588b073dea310813e82b0a63abfe3259b0aa 100644 (file)
@@ -15,6 +15,7 @@ import signal
 import stat
 import subprocess
 import sys
+import sysconfig
 import tempfile
 from typing import List
 import xml.etree.ElementTree as ET
@@ -23,6 +24,13 @@ import pytest
 sys.path.append(os.path.dirname(__file__))
 from gvtest import dot, ROOT, run_c #pylint: disable=C0413
 
+def is_mingw() -> bool:
+  """
+  are we running on MinGW?
+  """
+
+  return "mingw" in sysconfig.get_platform()
+
 def is_ndebug_defined() -> bool:
   """
   are assertions disabled in the Graphviz build under test?
@@ -373,7 +381,7 @@ def test_1314():
   # the execution did not fail as expected
   pytest.fail("dot incorrectly exited with success")
 
-@pytest.mark.xfail(strict=not is_ndebug_defined()) # FIXME
+@pytest.mark.xfail(strict=not is_ndebug_defined() and not is_mingw()) # FIXME
 def test_1408():
   """
   parsing particular ortho layouts should not cause an assertion failure