mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
Teach pre-commit try-repo to clone uncommitted changes
This commit is contained in:
parent
e04505a669
commit
bdc58cc33f
10 changed files with 148 additions and 62 deletions
|
|
@ -7,7 +7,6 @@ import os.path
|
|||
import pytest
|
||||
|
||||
from pre_commit import git
|
||||
from pre_commit.error_handler import FatalError
|
||||
from pre_commit.util import cmd_output
|
||||
from testing.util import git_commit
|
||||
|
||||
|
|
@ -23,11 +22,6 @@ def test_get_root_deeper(in_git_dir):
|
|||
assert os.path.normcase(git.get_root()) == expected
|
||||
|
||||
|
||||
def test_get_root_not_git_dir(in_tmpdir):
|
||||
with pytest.raises(FatalError):
|
||||
git.get_root()
|
||||
|
||||
|
||||
def test_get_staged_files_deleted(in_git_dir):
|
||||
in_git_dir.join('test').ensure()
|
||||
cmd_output('git', 'add', 'test')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue