11from collections import OrderedDict
22
3- from pre_commit .meta_hooks import check_files_matches_any
3+ from pre_commit .meta_hooks import check_hooks_apply
44from pre_commit .util import cwd
55from testing .fixtures import add_config_to_repo
66from testing .fixtures import git_dir
@@ -25,7 +25,7 @@ def test_hook_excludes_everything(
2525 add_config_to_repo (repo , config )
2626
2727 with cwd (repo ):
28- assert check_files_matches_any .main (()) == 1
28+ assert check_hooks_apply .main (()) == 1
2929
3030 out , _ = capsys .readouterr ()
3131 assert 'check-useless-excludes does not apply to this repository' in out
@@ -50,7 +50,7 @@ def test_hook_includes_nothing(
5050 add_config_to_repo (repo , config )
5151
5252 with cwd (repo ):
53- assert check_files_matches_any .main (()) == 1
53+ assert check_hooks_apply .main (()) == 1
5454
5555 out , _ = capsys .readouterr ()
5656 assert 'check-useless-excludes does not apply to this repository' in out
@@ -75,7 +75,7 @@ def test_hook_types_not_matched(
7575 add_config_to_repo (repo , config )
7676
7777 with cwd (repo ):
78- assert check_files_matches_any .main (()) == 1
78+ assert check_hooks_apply .main (()) == 1
7979
8080 out , _ = capsys .readouterr ()
8181 assert 'check-useless-excludes does not apply to this repository' in out
@@ -100,7 +100,7 @@ def test_hook_types_excludes_everything(
100100 add_config_to_repo (repo , config )
101101
102102 with cwd (repo ):
103- assert check_files_matches_any .main (()) == 1
103+ assert check_hooks_apply .main (()) == 1
104104
105105 out , _ = capsys .readouterr ()
106106 assert 'check-useless-excludes does not apply to this repository' in out
@@ -124,7 +124,7 @@ def test_valid_includes(
124124 add_config_to_repo (repo , config )
125125
126126 with cwd (repo ):
127- assert check_files_matches_any .main (()) == 0
127+ assert check_hooks_apply .main (()) == 0
128128
129129 out , _ = capsys .readouterr ()
130130 assert out == ''
0 commit comments