diff --git a/python-snuggs.spec b/python-snuggs.spec index 24ed1a3..4fd834a 100644 --- a/python-snuggs.spec +++ b/python-snuggs.spec @@ -2,12 +2,13 @@ Name: python-%{srcname} Version: 1.4.7 -Release: 14%{?dist} +Release: 15%{?dist} Summary: Snuggs are S-expressions for Numpy License: MIT URL: https://github.com/mapbox/snuggs Source0: %pypi_source +Patch0: https://salsa.debian.org/debian-gis-team/python-snuggs/-/raw/master/debian/patches/test.patch BuildArch: noarch diff --git a/test.patch b/test.patch new file mode 100644 index 0000000..7c25d94 --- /dev/null +++ b/test.patch @@ -0,0 +1,30 @@ +Description: Fix test failures. +Author: Bas Couwenberg +Bug: https://github.com/mapbox/snuggs/issues/27 + +--- a/test_snuggs.py ++++ b/test_snuggs.py +@@ -191,6 +191,7 @@ def test_masked_arr(): + + + # Parse and syntax error testing. ++@pytest.mark.xfail(strict=False, reason="https://github.com/mapbox/snuggs/issues/27") + def test_missing_closing_paren(): + with pytest.raises(SyntaxError) as excinfo: + snuggs.eval("(+ 1 2") +@@ -206,6 +207,7 @@ def test_missing_func(): + assert str(excinfo.value) == "'0' is not a function or operator" + + ++@pytest.mark.xfail(strict=False, reason="https://github.com/mapbox/snuggs/issues/27") + def test_missing_func2(): + with pytest.raises(SyntaxError) as excinfo: + snuggs.eval("(# 1 2)") +@@ -221,6 +223,7 @@ def test_undefined_var(): + assert str(excinfo.value) == "name 'bogus' is not defined" + + ++@pytest.mark.xfail(strict=False, reason="https://github.com/mapbox/snuggs/issues/27") + def test_bogus_higher_order_func(): + with pytest.raises(SyntaxError) as excinfo: + snuggs.eval("((bogus * 2) 2)")