jenkins-bot has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/676753 )
Change subject: [tests] Drop test for removed deprecated methods ......................................................................
[tests] Drop test for removed deprecated methods
Commit d203902 removed our deprecated new_ns() and new_title() methods but not the corresponding test, causing our unit tests to fail...
% python -m tests.logentries_tests TestDeprecatedMethods
====================================================================== ERROR: test_move_entry_dewp (__main__.TestDeprecatedMethods) Test deprecated MoveEntry methods on wikipedia:de ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/atagar/pywikibot/core/tests/aspects.py", line 626, in wrapped_method func(self, key) File "/home/atagar/pywikibot/core/tests/logentries_tests.py", line 298, in test_move_entry self.assertIsInstance(logentry.new_ns(), int) File "/home/atagar/pywikibot/core/pywikibot/logentries.py", line 92, in __getattr__ return super().__getattribute__(item) AttributeError: 'MoveEntry' object has no attribute 'new_ns'
Change-Id: I0e4bd3251d26626895f4b517f1652b2cc8f3177e --- M tests/logentries_tests.py 1 file changed, 0 insertions(+), 11 deletions(-)
Approvals: Xqt: Looks good to me, approved DannyS712: Looks good to me, but someone else must approve jenkins-bot: Verified
diff --git a/tests/logentries_tests.py b/tests/logentries_tests.py index e265212..57dc852 100644 --- a/tests/logentries_tests.py +++ b/tests/logentries_tests.py @@ -292,17 +292,6 @@
"""Test cases for deprecated logentry methods."""
- def test_move_entry(self, key): - """Test deprecated MoveEntry methods.""" - logentry = self._get_logentry('move') - self.assertIsInstance(logentry.new_ns(), int) - self.assertOneDeprecationParts('pywikibot.logentries.MoveEntry.new_ns', - 'target_ns.id') - - self.assertEqual(logentry.new_title(), logentry.target_page) - self.assertOneDeprecationParts( - 'pywikibot.logentries.MoveEntry.new_title', 'target_page') - def test_logentry_title(self, key): """Test title and page return the same instance.""" # Request multiple log entries in the hope that one might have no
pywikibot-commits@lists.wikimedia.org