Skip to content

Commit c372147

Browse files
timobrembeckclaudep
authored andcommitted
Disable urllib warnings during tests
1 parent 46968e0 commit c372147

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

linkcheck/tests/test_linkcheck.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
from unittest.mock import patch
55

66
import requests_mock
7+
import urllib3
78
from django.apps import apps
89
from django.conf import settings
910
from django.contrib.auth.models import User
@@ -349,6 +350,10 @@ def test_internal_check_media_utf8(self):
349350

350351
@override_settings(SITE_DOMAIN='example.com')
351352
class ExternalCheckTestCase(LiveServerTestCase):
353+
354+
def setUp(self):
355+
urllib3.disable_warnings()
356+
352357
def test_external_check_200(self):
353358
uv = Url(url=f"{self.live_server_url}/http/200/")
354359
uv.check_url()

0 commit comments

Comments
 (0)