jenkins-bot has submitted this change and it was merged.
Change subject: [FIX] site_tests: Expect long if necessary
......................................................................
[FIX] site_tests: Expect long if necessary
On the appveyor Windows builds, the maximum int number is to low to represent
the timestamp in an int and it uses a long. But the test explicitly requires an
int which is technically not possible.
Bug: T113146
Change-Id: I7c054c55cbb3334eed14faabdb09a69cbb18b48c
---
M tests/site_tests.py
1 file changed, 6 insertions(+), 2 deletions(-)
Approvals:
Xqt: Looks good to me, approved
jenkins-bot: Verified
diff --git a/tests/site_tests.py b/tests/site_tests.py
index 2b41257..26227d0 100644
--- a/tests/site_tests.py
+++ b/tests/site_tests.py
@@ -22,8 +22,11 @@
from pywikibot import config
from pywikibot import async_request, page_put_queue
from pywikibot.comms import http
-from pywikibot.tools import MediaWikiVersion
from pywikibot.data import api
+from pywikibot.tools import (
+ MediaWikiVersion,
+ PY2,
+)
from tests.aspects import (
unittest, TestCase, DeprecationTestCase,
@@ -1062,7 +1065,8 @@
self.assertIsInstance(entry, tuple)
self.assertIsInstance(entry[0], pywikibot.Page)
self.assertIsInstance(entry[1], basestring)
- self.assertIsInstance(entry[2], int)
+ self.assertIsInstance(
+ entry[2], long if PY2 and entry[2] > sys.maxint else int) # noqa
self.assertIsInstance(entry[3], basestring)
def test_logpages_dump(self):
--
To view, visit
https://gerrit.wikimedia.org/r/239566
To unsubscribe, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I7c054c55cbb3334eed14faabdb09a69cbb18b48c
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: XZise <CommodoreFabianus(a)gmx.de>
Gerrit-Reviewer: John Vandenberg <jayvdb(a)gmail.com>
Gerrit-Reviewer: Ladsgroup <ladsgroup(a)gmail.com>
Gerrit-Reviewer: Xqt <info(a)gno.de>
Gerrit-Reviewer: jenkins-bot <>