diff options
author | Sebastian Thiel <sebastian.thiel@icloud.com> | 2022-05-18 07:43:53 +0800 |
---|---|---|
committer | Sebastian Thiel <sebastian.thiel@icloud.com> | 2022-05-18 07:43:53 +0800 |
commit | 21ec529987d10e0010badd37f8da3274167d436f (patch) | |
tree | a3394cfe902ce7edd07c89420c21c13274a2d295 /test/test_clone.py | |
parent | b30720ee4d9762a03eae4fa7cfa4b0190d81784d (diff) | |
download | gitpython-21ec529987d10e0010badd37f8da3274167d436f.tar.gz |
Run everything through 'black'
That way people who use it won't be deterred, while it unifies style
everywhere.
Diffstat (limited to 'test/test_clone.py')
-rw-r--r-- | test/test_clone.py | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/test/test_clone.py b/test/test_clone.py index e9f6714d..6bd944f9 100644 --- a/test/test_clone.py +++ b/test/test_clone.py @@ -17,16 +17,23 @@ class TestClone(TestBase): @with_rw_directory def test_checkout_in_non_empty_dir(self, rw_dir): non_empty_dir = Path(rw_dir) - garbage_file = non_empty_dir / 'not-empty' - garbage_file.write_text('Garbage!') + garbage_file = non_empty_dir / "not-empty" + garbage_file.write_text("Garbage!") # Verify that cloning into the non-empty dir fails while complaining about # the target directory not being empty/non-existent try: self.rorepo.clone(non_empty_dir) except git.GitCommandError as exc: - self.assertTrue(exc.stderr, "GitCommandError's 'stderr' is unexpectedly empty") - expr = re.compile(r'(?is).*\bfatal:\s+destination\s+path\b.*\bexists\b.*\bnot\b.*\bempty\s+directory\b') - self.assertTrue(expr.search(exc.stderr), '"%s" does not match "%s"' % (expr.pattern, exc.stderr)) + self.assertTrue( + exc.stderr, "GitCommandError's 'stderr' is unexpectedly empty" + ) + expr = re.compile( + r"(?is).*\bfatal:\s+destination\s+path\b.*\bexists\b.*\bnot\b.*\bempty\s+directory\b" + ) + self.assertTrue( + expr.search(exc.stderr), + '"%s" does not match "%s"' % (expr.pattern, exc.stderr), + ) else: self.fail("GitCommandError not raised") |