From d02bc415fa076de93b9ce4e25781097d68acc65c Mon Sep 17 00:00:00 2001 From: Matthew Feickert Date: Wed, 15 Jun 2022 21:04:21 -0500 Subject: [PATCH 1/2] chore: Update pre-commit/pre-commit-hooks example to v4.3.0 --- pages/developers/style.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/developers/style.md b/pages/developers/style.md index 4490b40..c5756bd 100644 --- a/pages/developers/style.md +++ b/pages/developers/style.md @@ -26,7 +26,7 @@ Here is a minimal `.pre-commit-config.yaml` file with some handy options: ```yaml repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: "v4.2.0" + rev: "v4.3.0" hooks: - id: check-added-large-files - id: check-case-conflict From e60aa396fdc486c78c57ab2482fb0c8928cb37a0 Mon Sep 17 00:00:00 2001 From: Matthew Feickert Date: Wed, 15 Jun 2022 21:06:38 -0500 Subject: [PATCH 2/2] feat: Add 'name-tests-test' to pre-commit hooks example * Add the 'name-tests-test' pre-commit hooks which verifies that test files under tests/ conform to pytest naming conventions. - Use the '--pytest-test-first' option to match the 'test_.*\.py' naming convention. --- pages/developers/style.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pages/developers/style.md b/pages/developers/style.md index c5756bd..7230997 100644 --- a/pages/developers/style.md +++ b/pages/developers/style.md @@ -36,6 +36,8 @@ repos: - id: debug-statements - id: end-of-file-fixer - id: mixed-line-ending + - id: name-tests-test + args: ["--pytest-test-first"] - id: requirements-txt-fixer - id: trailing-whitespace ```