Commit b8bcb462 authored by Chris Lamb's avatar Chris Lamb 💬

ps2ascii > 9.21 now varies on timezone, so temporarily skip this test for now.

parent 71493966
......@@ -18,11 +18,12 @@
# along with diffoscope. If not, see <https://www.gnu.org/licenses/>.
import pytest
import subprocess
from diffoscope.comparators.ps import PsFile
from ..utils.data import load_fixture, get_data
from ..utils.tools import skip_unless_tools_exist
from ..utils.tools import skip_unless_tools_exist, skip_unless_tool_is_at_most
from ..utils.nonexisting import assert_non_existing
......@@ -30,6 +31,10 @@ ps1 = load_fixture('test1.ps')
ps2 = load_fixture('test2.ps')
def ps2ascii_version():
return subprocess.check_output(('ps2ascii', '--version')).decode('utf-8')
def test_identification(ps1):
assert isinstance(ps1, PsFile)
......@@ -50,7 +55,7 @@ def test_internal_diff(differences):
assert differences.unified_diff == expected_diff
@skip_unless_tools_exist('ps2ascii')
@skip_unless_tool_is_at_most('ps2ascii', ps2ascii_version, '9.21')
def test_text_diff(differences):
expected_diff = get_data('ps_text_expected_diff')
assert differences.details[0].unified_diff == expected_diff
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment