Skip to content

Conversation

pytorchbot
Copy link
Collaborator

Refactor the backend test suites to use pytest. This includes the following changes:

  • Define pytest markers for each backend and test flow (recipe). This allows for easy filter, such as by running pytest some/path/... -m backend_xnnpack.
  • Use a parameterized pytest fixture to handle test generation / expansion for each test flow.
  • Switch to using the pytest-json-report plugin for reporting. Update the markdown generation script to take json.
  • Shim the existing unittest-based logic for op tests.
    • I've updated add.py to show what they should look like long-term. I've also just updated the model tests, since there aren't as many. I'll update the remaining op tests later in this stack, though this is purely to clean up the code. The shimming logic makes them work properly with pytest in this PR.
  • Update the backend test CI to use pytest.

This also has the benefit of making the jobs much faster by leveraging parallel execution. I've also added a repro command to the markdown summary.

Refactor the backend test suites to use pytest. This includes the
following changes:
* Define pytest markers for each backend and test flow (recipe). This
allows for easy filter, such as by running `pytest some/path/... -m
backend_xnnpack`.
* Use a parameterized pytest fixture to handle test generation /
expansion for each test flow.
* Switch to using the pytest-json-report plugin for reporting. Update
the markdown generation script to take json.
* Shim the existing unittest-based logic for op tests.
* I've updated add.py to show what they should look like long-term. I've
also just updated the model tests, since there aren't as many. I'll
update the remaining op tests later in this stack, though this is purely
to clean up the code. The shimming logic makes them work properly with
pytest in this PR.
 * Update the backend test CI to use pytest.

This also has the benefit of making the jobs much faster by leveraging
parallel execution. I've also added a repro command to the markdown
summary.

(cherry picked from commit d09dd79)
Copy link

pytorch-bot bot commented Sep 29, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/14661

Note: Links to docs will display an error until the docs builds have been completed.

❌ 8 New Failures, 4 Pending

As of commit 04478d3 with merge base e0dda90 (image):

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Sep 29, 2025
@GregoryComer GregoryComer merged commit 0a02c6a into release/1.0 Sep 29, 2025
317 of 330 checks passed
@GregoryComer GregoryComer deleted the cherry-pick-14456-by-pytorch_bot_bot_ branch September 29, 2025 21:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants