Thanks to visit codestin.com
Credit goes to github.com

Skip to content

feat: Add 'name-tests-test' to pre-commit hooks #9

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 23, 2022

Conversation

matthewfeickert
Copy link
Member

@matthewfeickert matthewfeickert commented Jun 16, 2022

Motivated by scikit-hep/scikit-hep.github.io#227 and complimentary to PR scikit-hep/scikit-hep.github.io#231.

  • Update pre-commit/pre-commit-hooks to v4.3.0
  • 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.

@matthewfeickert matthewfeickert added the enhancement New feature or request label Jun 16, 2022
@matthewfeickert matthewfeickert self-assigned this Jun 16, 2022
@matthewfeickert matthewfeickert requested a review from henryiii June 16, 2022 02:29
* 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.
@matthewfeickert matthewfeickert force-pushed the feat/add-name-tests-test branch from e3a0f04 to ea30722 Compare June 22, 2022 15:46
@henryiii
Copy link
Collaborator

Could you also add a check for this being used? No need to check for the arg setting, but adding this as a check would be ideal.

@henryiii
Copy link
Collaborator

henryiii commented Jun 22, 2022

Oh, I didn't add individual checks for hooks (yet). Nevermind.

@henryiii henryiii merged commit 8a4f9f8 into main Jun 23, 2022
@henryiii henryiii deleted the feat/add-name-tests-test branch June 23, 2022 02:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants