def METHOD_NAME(tmpdir, tempdir_factory, store, cap_out):
    target = str(tmpdir.join('tmpl'))
    tmp_git_dir = git_dir(tempdir_factory)
    with cwd(tmp_git_dir):
        cmd_output('git', 'config', 'init.templateDir', target)
        init_templatedir(
            C.CONFIG_FILE, store, target, hook_types=['pre-commit'],
        )
    lines = cap_out.get().splitlines()
    assert len(lines) == 1
    assert lines[0].startswith('pre-commit installed at')