]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-125669: Do not run `-ugui` tests by default on `make test` (#125730)
authorsobolevn <mail@sobolevn.me>
Wed, 30 Oct 2024 14:14:22 +0000 (17:14 +0300)
committerGitHub <noreply@github.com>
Wed, 30 Oct 2024 14:14:22 +0000 (17:14 +0300)
Adds `make ci` target for use in CI and keeping `make test` for the local development.

.github/workflows/build.yml
.github/workflows/reusable-macos.yml
.github/workflows/reusable-ubuntu.yml
Doc/using/configure.rst
Makefile.pre.in
Misc/NEWS.d/next/Tests/2024-10-21-14-10-56.gh-issue-125730.kcWbvI.rst [new file with mode: 0644]

index d1e9fff37d3c2dd25590ef05244153c25a5e973e..083b07156674df0d1611ad9519681e4948ba1e04 100644 (file)
@@ -468,7 +468,7 @@ jobs:
     - name: Display build info
       run: make pythoninfo
     - name: Tests
-      run: xvfb-run make test
+      run: xvfb-run make ci
 
   build_tsan:
     name: 'Thread sanitizer'
index bfa5f69defb87c1a3db38015cb9af4768a96271d..915481d0737c7dd21a0aea2b9bb6ba609a1e0d44 100644 (file)
@@ -69,4 +69,4 @@ jobs:
         --fail-on-improvement
         --path-prefix="./"
     - name: Tests
-      run: make test
+      run: make ci
index 18e2e471e60e8d95cea8d9634fc5f9162feb297a..f0ca6a9e7ed79306909c2a7df2a7a32da78a0fe0 100644 (file)
@@ -105,4 +105,4 @@ jobs:
       run: sudo mount "$CPYTHON_RO_SRCDIR" -oremount,rw
     - name: Tests
       working-directory: ${{ env.CPYTHON_BUILDDIR }}
-      run: xvfb-run make test
+      run: xvfb-run make ci
index 0e7b1be5b4bc2e2215e9ee9226bd2888a416cd90..83994af795e3fc9438f9035e05291500d40f7658 100644 (file)
@@ -1142,13 +1142,21 @@ make test
 ^^^^^^^^^
 
 Build the ``all`` target and run the Python test suite with the
-``--fast-ci`` option. Variables:
+``--fast-ci`` option without GUI tests. Variables:
 
 * ``TESTOPTS``: additional regrtest command-line options.
 * ``TESTPYTHONOPTS``: additional Python command-line options.
 * ``TESTTIMEOUT``: timeout in seconds (default: 10 minutes).
 
 
+make ci
+^^^^^^^
+
+This is similar to ``make test``, but uses the ``-ugui`` to also run GUI tests.
+
+.. versionadded:: 3.14
+
+
 make buildbottest
 ^^^^^^^^^^^^^^^^^
 
index db5bad8752e541e6f751a56d9c38e70135e880f0..aa7fa4e29d84c2abb636878ee90886aaae6e45b4 100644 (file)
@@ -2104,6 +2104,12 @@ cleantest: all
 # Similar to buildbottest, but use --fast-ci option, instead of --slow-ci.
 .PHONY: test
 test: all
+       $(TESTRUNNER) --fast-ci -u-gui --timeout=$(TESTTIMEOUT) $(TESTOPTS)
+
+# Run a basic set of regression tests inside the CI.
+# This excludes some tests that are particularly resource-intensive.
+# Similar to test, but also runs GUI tests.
+ci: all
        $(TESTRUNNER) --fast-ci --timeout=$(TESTTIMEOUT) $(TESTOPTS)
 
 # Run the test suite for both architectures in a Universal build on OSX.
diff --git a/Misc/NEWS.d/next/Tests/2024-10-21-14-10-56.gh-issue-125730.kcWbvI.rst b/Misc/NEWS.d/next/Tests/2024-10-21-14-10-56.gh-issue-125730.kcWbvI.rst
new file mode 100644 (file)
index 0000000..061a1f9
--- /dev/null
@@ -0,0 +1,2 @@
+Change ``make test`` to not run GUI tests by default. Use ``make ci`` to run
+tests with GUI tests instead.