Skip to content

Python unit tests do not run on pull requests — intended? #17975

Description

@RAJUSHANIGARAPU

The Python unit-tests job is gated to scheduled and manual runs, so it never runs on a pull request or a push.

.github/workflows/ci-python.yml:46:

  unit-tests:
    name: Unit Tests
    if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'

That covers 673 test functions across 39 files under py/test/unit, on a 6-way matrix (Python 3.10 / 3.14 × ubuntu / macos / windows).

I am asking rather than reporting, because the condition is written explicitly and may well be a deliberate trade — unit tests on six platforms is not free, and the browser jobs may be considered sufficient signal on a PR. But it is unusual enough (unit tests are normally the cheapest thing to run on a PR) that it looked worth confirming rather than assuming.

If it is deliberate, a comment on that line would save the next person the same question.

Separately: eight tests that no target includes

These two files look unreachable from any Bazel target, which is a different situation from the above:

py/test/selenium/webdriver/common/print_pdf_tests.py (4 tests) — the path appears in py/BUILD.bazel only inside exclude lists, at lines 989 and 1132, and in no srcs:

exclude = BIDI_TESTS + ACTIONS_TESTS + FEATURE_TESTS + DRIVER_FINDER_TESTS +
          ["test/selenium/webdriver/common/print_pdf_tests.py"] + ...

py/test/selenium/webdriver/ie/ie_launcher_tests.py (4 tests) — py/BUILD.bazel:977:

DEFAULT_BROWSER_TESTS = [b for b in BROWSER_TESTS if b != "ie"]

which drives the suite generation at 1005, 1027, 1060, 1071, 1092 and 1117, so no target is emitted for ie. ie does not appear in any workflow either.

I checked this statically from a shallow clone and did not run Bazel, so I may have missed a target that picks them up another way — worth a second pair of eyes before acting on it.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions