jedcunningham commented on code in PR #28773:
URL: https://github.com/apache/airflow/pull/28773#discussion_r1066240841
##########
.pre-commit-config.yaml:
##########
@@ -577,6 +577,14 @@ repos:
files: \.*example_dags.*\.py$
exclude: ^airflow/_vendor/
pass_filenames: true
+ - id: check-xfail-usage-in-test-code
+ language: pygrep
+ name: Don't use xfail in tests
+ description: xfail is not recommended as a test meant to fail is
generally not meaningful
+ entry: "@pytest.mark.xfail"
+ pass_filenames: true
+ files: ^tests/.*\.py$
+ exclude:
^airflow/|^docs/|^tests/always/test_project_structure.py|^tests/jobs/test_backfill_job.py
Review Comment:
Why do we need `^airflow` and `^docs` here, if we are only matching
`^tests/.*\.py$`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]