Skip to content

Commit

Permalink
TST: Add condition to linprog test bug 5400
Browse files Browse the repository at this point in the history
TestLinprogSimplexNoPresolve::test_bug_5400 currently fails on Azure's
Python 3.6 32 bit linux test suite, but, should still pass all other
tests. It was marked with an xfail, that has been modified to only occur
on 32 bit linux systems.
  • Loading branch information
Kai-Striega committed Jun 2, 2019
1 parent edd50e2 commit a9e17e6
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion scipy/optimize/tests/test_linprog.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Unit test for Linear Programming
"""
from __future__ import division, print_function, absolute_import
import sys

import numpy as np
from numpy.testing import (assert_, assert_allclose, assert_equal,
Expand Down Expand Up @@ -1404,7 +1405,12 @@ class TestLinprogSimplexNoPresolve(LinprogSimplexTests):
def setup_method(self):
self.options = {'presolve': False}

@pytest.mark.xfail(reason='Fails with warning on 32-bit linux')
is_32_bit = np.intp(0).itemsize < 8
is_linux = sys.platform.startswith('linux')

@pytest.mark.xfail(
condition=is_32_bit and is_linux,
reason='Fails with warning on 32-bit linux')
def test_bug_5400(self):
super(TestLinprogSimplexNoPresolve, self).test_bug_5400()

Expand Down

0 comments on commit a9e17e6

Please sign in to comment.