site_tests

Tests in tests.site_tests:

Available tests

class tests.site_tests.SiteRandomTestCase(*args, **kwargs)[source]

Test random methods of a site.

testRandompages()[source]

Test the site.randompages() method.

class tests.site_tests.SiteSysopTestCase(*args, **kwargs)[source]

Test site method using a sysop account.

testDeletedrevs()[source]

Test the site.deletedrevs() method.

class tests.site_tests.SiteUserTestCase(*args, **kwargs)[source]

Test site method using a user.

testLogEvents()[source]

Test the site.logevents() method.

testRecentchanges()[source]

Test the site.recentchanges() method.

testSearch()[source]

Test the site.search() method.

testUsercontribs()[source]

Test the site.usercontribs() method.

testWatchlistrevs()[source]

Test the site.watchlist_revs() method.

class tests.site_tests.SiteUserTestCase2(*args, **kwargs)[source]

More tests that rely on a user account.

testPatrol()[source]

Test the site.patrol() method.

testUsers()[source]

Test the site.users() method.

class tests.site_tests.TestCommonsSite(*args, **kwargs)[source]

Test cases for Site methods on Commons.

class tests.site_tests.TestDataSiteClientPreloading(*args, **kwargs)[source]

Test DataSite.preloaditempages for client pages.

test_non_item()[source]

Test that ItemPage preloading works with Page generator.

class tests.site_tests.TestDataSitePreloading(*args, **kwargs)[source]

Test DataSite.preloaditempages for repo pages.

test_item()[source]

Test that ItemPage preloading works for Item objects.

test_item_as_page()[source]

Test that ItemPage preloading works for Page objects.

class tests.site_tests.TestImageUsage(*args, **kwargs)[source]

Test cases for Site.imageusage method.

imagepage

Find an image which is used on a page.

If there are no images included in pages it’ll skip all tests.

Note: This is not implemented as setUpClass which would be invoked while initialising all tests, to reduce chance of an error preventing all tests from running.

test_image_usage()[source]

Test the site.imageusage() method.

test_image_usage_in_namespaces()[source]

Test the site.imageusage() method with namespaces.

test_image_usage_in_redirects()[source]

Test the site.imageusage() method on redirects only.

test_image_usage_no_redirect_filter()[source]

Test the site.imageusage() method with redirects.

class tests.site_tests.TestNonEnglishWikipediaSite(*args, **kwargs)[source]

Test Site Object on Nynorsk Wikipedia.

class tests.site_tests.TestSiteAPILimits(*args, **kwargs)[source]

Test cases for Site method that use API limits.

class tests.site_tests.TestSiteExtensions(*args, **kwargs)[source]

Test cases for Site extensions.

class tests.site_tests.TestSiteInfo(*args, **kwargs)[source]

Test cases for Site metadata and capabilities.

testSiteinfo()[source]

Test the siteinfo property.

class tests.site_tests.TestSiteLoadRevisions(*args, **kwargs)[source]

Test cases for Site.loadrevision() method.

testLoadRevisions_basic()[source]

Test the site.loadrevisions() method.

testLoadRevisions_excludeuser()[source]

Test the site.loadrevisions() method, excluding user.

testLoadRevisions_getText()[source]

Test the site.loadrevisions() method with getText=True.

testLoadRevisions_querycontinue()[source]

Test the site.loadrevisions() method with query-continue.

testLoadRevisions_rev_id()[source]

Test the site.loadrevisions() method, listing based on rev_id.

testLoadRevisions_revdir()[source]

Test the site.loadrevisions() method with rvdir=True.

testLoadRevisions_revids()[source]

Test the site.loadrevisions() method, listing based on revid.

testLoadRevisions_timestamp()[source]

Test the site.loadrevisions() method, listing based on timestamp.

testLoadRevisions_user()[source]

Test the site.loadrevisions() method, filtering by user.

class tests.site_tests.TestSiteLoadRevisionsSysop(*args, **kwargs)[source]

Test cases for Site.loadrevision() method.

test_rollback()[source]

Test the site.loadrevisions() method with rollback.

class tests.site_tests.TestSiteObject(*args, **kwargs)[source]

Test cases for Site methods.

testAllCategories()[source]

Test the site.allcategories() method.

testAllImages()[source]

Test the site.allimages() method.

Test the site.alllinks() method.

testAllPages()[source]

Test the site.allpages() method.

testApiMethods()[source]

Test generic ApiSite methods.

testBaseMethods()[source]

Test cases for BaseSite methods.

testBlocks()[source]

Test the site.blocks() method.

testConstructors()[source]

Test cases for site constructors.

testEnglishSpecificMethods()[source]

Test Site methods using English specific inputs and outputs.

testExturlusage()[source]

Test the site.exturlusage() method.

testLanguageMethods()[source]

Test cases for languages() and related methods.

testLinkMethods()[source]

Test site methods for getting links to and from a page.

testNamespaceMethods()[source]

Test cases for methods manipulating namespace names.

testPageMethods()[source]

Test ApiSite methods for getting page-specific info.

test_allusers()[source]

Test the site.allusers() method.

test_allusers_with_prefix()[source]

Test the site.allusers(prefix=..) method.

test_allusers_with_start()[source]

Test the site.allusers(start=..) method.

class tests.site_tests.TestSiteObjectDeprecatedFunctions(*args, **kwargs)[source]

Test cases for Site deprecated methods.

test_live_version()[source]

Test live_version.

test_token()[source]

Test ability to get page tokens.

class tests.site_tests.TestSiteTokens(*args, **kwargs)[source]

Test cases for tokens in Site methods.

setUp()[source]

Store version.

tearDown()[source]

Restore version.

test_tokens_in_mw_119()[source]

Test ability to get page tokens.

test_tokens_in_mw_120_124wmf18()[source]

Test ability to get page tokens.

test_tokens_in_mw_124wmf19()[source]

Test ability to get page tokens.

class tests.site_tests.TestWiktionarySite(*args, **kwargs)[source]

Test Site Object on English Wiktionary.