tests.edit_failure_tests module#
Tests for edit failures.
These tests should never write to the wiki, unless something has broken badly.
These tests use special code ‘write = -1’ for edit failures.
- class tests.edit_failure_tests.TestActionFailure(*args, **kwargs)[source]#
Bases:
RequireLoginMixin
,SiteWriteMixin
,CheckHostnameMixin
,TestCase
Test cases for actions which should fail to save.
- abstract_class = False#
- code = 'test'#
- family = 'wikipedia'#
- login = True#
- net = True#
- site = True#
- sites = {'wikipedia:test': {'code': 'test', 'family': 'wikipedia'}}#
- write = -1#
- class tests.edit_failure_tests.TestSaveFailure(*args, **kwargs)[source]#
Bases:
RequireLoginMixin
,SiteWriteMixin
,CheckHostnameMixin
,TestCase
Test cases for edits which should fail to save.
- abstract_class = False#
- code = 'test'#
- family = 'wikipedia'#
- login = True#
- net = True#
- site = True#
- sites = {'wikipedia:test': {'code': 'test', 'family': 'wikipedia'}}#
- write = -1#
- class tests.edit_failure_tests.TestWikibaseSaveTest(*args, **kwargs)[source]#
Bases:
RequireLoginMixin
,SiteWriteMixin
,CheckHostnameMixin
,WikibaseTestCase
Test case for WikibasePage.save on Wikidata test site.
- abstract_class = False#
- code = 'test'#
- family = 'wikidata'#
- login = True#
- net = True#
- site = True#
- sites = {'wikidata:test': {'code': 'test', 'family': 'wikidata'}}#
- test_WbMonolingualText_invalid_language()[source]#
Attempt adding a monolingual text with an invalid language.
- test_WbMonolingualText_invalid_text()[source]#
Attempt adding a monolingual text with invalid non-string text.
- wikibase = True#
- write = -1#