Skip to content
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

[pre-commit.ci] pre-commit autoupdate #223

Merged
merged 2 commits into from
Apr 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@ repos:
- id: check-useless-excludes

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
rev: v4.4.0
hooks:
- id: debug-statements

- repo: https://github.com/asottile/blacken-docs
rev: v1.12.1
rev: 1.13.0
hooks:
- id: blacken-docs
# args: ["-l100"]

- repo: https://github.com/PyCQA/flake8
rev: 5.0.4
rev: 6.0.0
hooks:
- id: flake8
exclude: >-
Expand All @@ -26,7 +26,7 @@ repos:
)

- repo: https://github.com/psf/black
rev: 22.10.0
rev: 23.3.0
hooks:
- id: black
# args: ["-l100"]
1 change: 1 addition & 0 deletions doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@
# If false, no module index is generated.
# latex_domain_indices = True


# PyHamcrest customization: Don't skip BaseMatcher's _matches method
def skip_member(app, what, name, obj, skip, options):
if skip and str(obj).find("BaseMatcher._matches") >= 0:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ def matches(
self, item: Mapping[K, V], mismatch_description: Optional[Description] = None
) -> bool:
for key, value_matcher in self.value_matchers:

try:
if key not in item:
if mismatch_description:
Expand Down
1 change: 0 additions & 1 deletion tests/hamcrest_unit_test/core/nevermatch.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@


class NeverMatch(BaseMatcher):

mismatch_description = "NEVERMATCH"

def matches(self, item, mismatch_description=None):
Expand Down
3 changes: 0 additions & 3 deletions tests/hamcrest_unit_test/object/hasproperty_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,11 @@


class OnePropertyOldStyle:

field = "value"
field2 = "value2"


class ThreePropertiesNewStyle(object):

field = "value"
field2 = "value2"
field3 = "value3"
Expand Down Expand Up @@ -65,7 +63,6 @@ def __getattribute__(self, name):


class ObjectPropertyMatcher(object):

match_sets = (
("old-style: %s", OnePropertyOldStyle),
("new-style: %s", ThreePropertiesNewStyle),
Expand Down