jenkins-bot has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/894182 )
Change subject: [tests] exclude proofwiki test on github ......................................................................
[tests] exclude proofwiki test on github
Change-Id: Ia5b39a646158a4047f2ba0ca54e07d237ce63e63 --- M tests/site_detect_tests.py 1 file changed, 20 insertions(+), 3 deletions(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/tests/site_detect_tests.py b/tests/site_detect_tests.py index 2298f92..918d76f 100755 --- a/tests/site_detect_tests.py +++ b/tests/site_detect_tests.py @@ -1,10 +1,11 @@ #!/usr/bin/env python3 """Test for site detection.""" # -# (C) Pywikibot team, 2014-2022 +# (C) Pywikibot team, 2014-2023 # # Distributed under the terms of the MIT license. # +import os import unittest from contextlib import suppress from http import HTTPStatus @@ -15,8 +16,9 @@ import pywikibot from pywikibot.exceptions import ServerError from pywikibot.site_detect import MWSite + from tests.aspects import PatchingTestCase, TestCase -from tests.utils import DrySite, skipping +from tests.utils import DrySite, expected_failure_if, skipping
class SiteDetectionTestCase(TestCase): @@ -56,7 +58,7 @@ """Test detection of MediaWiki sites."""
standard_version_sites = ( - 'http://www.proofwiki.org/wiki/$1', + # 'http://www.proofwiki.org/wiki/$1', 'http://www.ck-wissen.de/ckwiki/index.php?title=$1', 'http://en.citizendium.org/wiki/$1', # Server that hosts www.wikichristian.org is unreliable - it @@ -111,6 +113,12 @@ with self.subTest(url=urlparse(url).netloc): self.assertSite(url)
+ @expected_failure_if(os.getenv('GITHUB_ACTIONS')) # T331223 + def test_proofreadwiki(self): + """Test detection of proofwiki.org site.""" + # test is failing on github, see T331223 + self.assertSite('http://www.proofwiki.org/wiki/$1') + def test_non_standard_version_sites(self): """Test detection of non standard MediaWiki sites.""" for url in self.non_standard_version_sites:
pywikibot-commits@lists.wikimedia.org