From: Benjamin Peterson Date: Tue, 6 Feb 2018 17:29:21 +0000 (-0800) Subject: allow the test suite to pass if the strop module doesn't exist (GH-5566) X-Git-Tag: v2.7.15rc1~60 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0a18422b31e0d7549da5ddbf62194f8c583c2091;p=python allow the test suite to pass if the strop module doesn't exist (GH-5566) strop is highly legacy and can be safely compiled out in most installations. Let's not fail the test suite for its absence. --- diff --git a/Lib/test/test_strop.py b/Lib/test/test_strop.py index 81d078ed8d..50b8f6ebc3 100644 --- a/Lib/test/test_strop.py +++ b/Lib/test/test_strop.py @@ -2,11 +2,12 @@ import warnings warnings.filterwarnings("ignore", "strop functions are obsolete;", DeprecationWarning, r'test.test_strop|unittest') -import strop import unittest import sys from test import test_support +strop = test_support.import_module("strop") + class StropFunctionTestCase(unittest.TestCase):