jenkins-bot has submitted this change. ( 
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/831060 )

Change subject: [doc] Add description for PYWIKIBOT_TEST_AUTORUN and 
PYWIKIBOT_TEST_MODULES
......................................................................

[doc] Add description for PYWIKIBOT_TEST_AUTORUN and PYWIKIBOT_TEST_MODULES

Change-Id: Iae2b53210eebc3183f578603649cfe20232f7a9b
---
M tests/README.rst
M tests/script_tests.py
2 files changed, 20 insertions(+), 1 deletion(-)

Approvals:
  Xqt: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/tests/README.rst b/tests/README.rst
index f53fdd6..cbaee97 100644
--- a/tests/README.rst
+++ b/tests/README.rst
@@ -105,11 +105,29 @@
 Environment variables
 =====================

+**PYWIKIBOT_TEST_AUTORUN**
+  Enable script tests running automatically without specifying a generator.
+  The scripts are listed in :attr:`tests.script_tests.auto_run_script_list`.
+  Currently only *deeptest* uses it.
+
+**PYWIKIBOT_TEST_MODULES**
+  Only run tests given with this environment variable. Multiple tests must be
+  separated by a ``,`` without any white space. Available library tests are
+  listed in :ref:`Library tests` and script tests can be found in
+  :ref:`Script tests`. To enable only :mod:`tests.site_tests` and
+  :mod:`tests.wikibase_tests` set the environment variable as::
+
+    PYWIKIBOT_TEST_MODULES=site,wikibase
+
+  .. note:: test names must be given without subsequent ``_tests``.
+
 **PYWIKIBOT_TEST_RUNNING**
   This environment variable skips tests instead of raising
   :exc:`exceptions.MaxlagTimeoutError` when maximum retries attempted due to
   maxlag without success. It is also used by :mod:`tests.script_tests` for code
-  coverage. Github actions and Appveyor tests activate this variable.
+  coverage. Github actions and Appveyor tests activate this variable::
+
+    PYWIKIBOT_TEST_RUNNING=1

 **PYWIKIBOT_TEST_WRITE**
   There are also several other 'write' tests which also attempt to perform
diff --git a/tests/script_tests.py b/tests/script_tests.py
index 7afeb2f..777815b 100755
--- a/tests/script_tests.py
+++ b/tests/script_tests.py
@@ -76,6 +76,7 @@
         '8/80/Wikipedia-logo-v2.svg\n\n\n',
 }

+#:
 auto_run_script_list = [
     'archivebot',
     'blockpageschecker',

--
To view, visit https://gerrit.wikimedia.org/r/c/pywikibot/core/+/831060
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.wikimedia.org/r/settings

Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: Iae2b53210eebc3183f578603649cfe20232f7a9b
Gerrit-Change-Number: 831060
Gerrit-PatchSet: 1
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: Xqt <[email protected]>
Gerrit-Reviewer: jenkins-bot
Gerrit-MessageType: merged
_______________________________________________
Pywikibot-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to