mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
Merge pull request #602 from pre-commit/xdg_cache_dir
Adhere to XDG specification for cache dir.
This commit is contained in:
commit
9ff6818270
9 changed files with 50 additions and 17 deletions
|
|
@ -2,6 +2,7 @@ from __future__ import absolute_import
|
|||
from __future__ import unicode_literals
|
||||
|
||||
import argparse
|
||||
import os.path
|
||||
|
||||
import mock
|
||||
import pytest
|
||||
|
|
@ -121,10 +122,11 @@ def test_expected_fatal_error_no_git_repo(
|
|||
with cwd(tempdir_factory.get()):
|
||||
with pytest.raises(SystemExit):
|
||||
main.main([])
|
||||
log_file = os.path.join(mock_out_store_directory, 'pre-commit.log')
|
||||
assert cap_out.get() == (
|
||||
'An error has occurred: FatalError: git failed. '
|
||||
'Is it installed, and are you in a Git repository directory?\n'
|
||||
'Check the log at ~/.pre-commit/pre-commit.log\n'
|
||||
'Check the log at {}\n'.format(log_file)
|
||||
)
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue