MCPcopy Index your code
hub / github.com/pre-commit/pre-commit / test_always_run_alt_config

Function test_always_run_alt_config

tests/commands/run_test.py:441–457  ·  view source on GitHub ↗
(cap_out, store, repo_with_passing_hook)

Source from the content-addressed store, hash-verified

439
440
441def test_always_run_alt_config(cap_out, store, repo_with_passing_hook):
442 repo_root = '.'
443 config = read_config(repo_root)
444 config['repos'][0]['hooks'][0]['always_run'] = True
445 alt_config_file = 'alternate_config.yaml'
446 add_config_to_repo(repo_root, config, config_file=alt_config_file)
447
448 _test_run(
449 cap_out,
450 store,
451 repo_with_passing_hook,
452 {},
453 (b'Bash hook', b'Passed'),
454 0,
455 stage=False,
456 config_file=alt_config_file,
457 )
458
459
460def test_hook_verbose_enabled(cap_out, store, repo_with_passing_hook):

Callers

nothing calls this directly

Calls 3

read_configFunction · 0.90
add_config_to_repoFunction · 0.90
_test_runFunction · 0.85

Tested by

no test coverage detected