summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorent Xicluna <florent.xicluna@gmail.com>2010-08-14 20:51:58 (GMT)
committerFlorent Xicluna <florent.xicluna@gmail.com>2010-08-14 20:51:58 (GMT)
commit62829dc727fc708e54aa6f34e53759f7acfa8594 (patch)
treee072f692772208e8d6e1f03ebc1ad1162156040c
parent82a3f8afcb0716cf524b4f731e25b4d6dca554a4 (diff)
downloadcpython-62829dc727fc708e54aa6f34e53759f7acfa8594.zip
cpython-62829dc727fc708e54aa6f34e53759f7acfa8594.tar.gz
cpython-62829dc727fc708e54aa6f34e53759f7acfa8594.tar.bz2
Silence BytesWarning while testing exception
-rw-r--r--Lib/test/test_urllib.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/test/test_urllib.py b/Lib/test/test_urllib.py
index 159fd8a..35c7f51 100644
--- a/Lib/test/test_urllib.py
+++ b/Lib/test/test_urllib.py
@@ -572,7 +572,8 @@ class UnquotingTests(unittest.TestCase):
"%s" % result)
self.assertRaises((TypeError, AttributeError), urllib.parse.unquote, None)
self.assertRaises((TypeError, AttributeError), urllib.parse.unquote, ())
- self.assertRaises((TypeError, AttributeError), urllib.parse.unquote, b'')
+ with support.check_warnings(('', BytesWarning), quiet=True):
+ self.assertRaises((TypeError, AttributeError), urllib.parse.unquote, b'')
def test_unquoting_badpercent(self):
# Test unquoting on bad percent-escapes