Merge pull request #4138 from jdufresne/skip-known

Remove unused arguments from PillowTestCase.skipKnownBadTest()
This commit is contained in:
Andrew Murray 2019-10-13 06:42:02 +11:00 committed by GitHub
commit 02ca4a1a7f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -202,23 +202,12 @@ class PillowTestCase(unittest.TestCase):
self.assertTrue(value, msg + ": " + repr(actuals) + " != " + repr(targets)) self.assertTrue(value, msg + ": " + repr(actuals) + " != " + repr(targets))
def skipKnownBadTest(self, msg=None, platform=None, travis=None, interpreter=None): def skipKnownBadTest(self, msg=None):
# Skip if platform/travis matches, and # Skip if PILLOW_RUN_KNOWN_BAD is not true in the environment.
# PILLOW_RUN_KNOWN_BAD is not true in the environment.
if os.environ.get("PILLOW_RUN_KNOWN_BAD", False): if os.environ.get("PILLOW_RUN_KNOWN_BAD", False):
print(os.environ.get("PILLOW_RUN_KNOWN_BAD", False)) print(os.environ.get("PILLOW_RUN_KNOWN_BAD", False))
return return
skip = True
if platform is not None:
skip = sys.platform.startswith(platform)
if travis is not None:
skip = skip and (travis == bool(os.environ.get("TRAVIS", False)))
if interpreter is not None:
skip = skip and (
interpreter == "pypy" and hasattr(sys, "pypy_version_info")
)
if skip:
self.skipTest(msg or "Known Bad Test") self.skipTest(msg or "Known Bad Test")
def tempfile(self, template): def tempfile(self, template):