From ef754eeca6effa2ba2033a5f9dc6782b8a481ecc Mon Sep 17 00:00:00 2001 From: Magnus Jacobsson Date: Sat, 25 Jul 2020 23:24:15 +0200 Subject: [PATCH] Convert test_large_graphs.py to pytest --- tests/regression_tests/large/test_large_graphs.py | 6 +++--- tests/regression_tests/regression_tests.ps1 | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/regression_tests/large/test_large_graphs.py b/tests/regression_tests/large/test_large_graphs.py index b6f69c9b0..7c4d047ce 100644 --- a/tests/regression_tests/large/test_large_graphs.py +++ b/tests/regression_tests/large/test_large_graphs.py @@ -1,12 +1,12 @@ -from unittest import TestCase, skipIf +import pytest import subprocess import os import sys -class TestLargeGraphs(TestCase): - @skipIf(sys.platform == 'win32', reason='https://gitlab.com/graphviz/graphviz/-/issues/1710') +class TestLargeGraphs(): + @pytest.mark.skipif(sys.platform == 'win32', reason='https://gitlab.com/graphviz/graphviz/-/issues/1710') def test_long_chain(self): """ This test will fail on 32bit Windows machine if compiled with stack size < 16MB. diff --git a/tests/regression_tests/regression_tests.ps1 b/tests/regression_tests/regression_tests.ps1 index b9e05b1c5..ba146df64 100644 --- a/tests/regression_tests/regression_tests.ps1 +++ b/tests/regression_tests/regression_tests.ps1 @@ -7,4 +7,4 @@ Pop-Location # messages as an error, failing the pipeline. So we must redirect # stderr to stdout. The line noise at the end does so. See # https://stackoverflow.com/a/20950421/171898 for explanation. -python -m unittest discover large 2>&1 | %{ "$_" } +python -m pytest large 2>&1 | %{ "$_" } -- 2.40.0