jenkins-bot has submitted this change and it was merged.
Change subject: [FIX] Tests: Don't test patrol with revid pre 1.22 ......................................................................
[FIX] Tests: Don't test patrol with revid pre 1.22
In MediaWiki versions before 1.22 it's not possible to use patrol with revid, so don't use the revid.
Change-Id: Ia8d4d67fc6ca40330fa102ddb0e339d9934fd280 --- M tests/site_tests.py 1 file changed, 5 insertions(+), 1 deletion(-)
Approvals: John Vandenberg: Looks good to me, approved jenkins-bot: Verified
diff --git a/tests/site_tests.py b/tests/site_tests.py index b3ac597..ac60018 100644 --- a/tests/site_tests.py +++ b/tests/site_tests.py @@ -1327,9 +1327,13 @@ result = result[0] self.assertIsInstance(result, dict)
+ params = {'rcid': 0} + if mysite.version() >= MediaWikiVersion('1.22'): + params['revid'] = [0, 1] + try: # no such rcid, revid or too old revid - result = list(mysite.patrol(rcid=0, revid=[0, 1])) + result = list(mysite.patrol(**params)) except api.APIError as error: if error.code == u'badtoken': raise unittest.SkipTest(error)
pywikibot-commits@lists.wikimedia.org