diff --git a/tests/test_main.py b/tests/test_main.py index dfff719ac..8aa7ebd91 100644 --- a/tests/test_main.py +++ b/tests/test_main.py @@ -34,6 +34,9 @@ class TestMain(TestCase): self.assertTrue(os.path.exists("foo.txt")) def test_main_with_empty_git_dir_new_file(self): + tempdir = tempfile.mkdtemp() + os.chdir(tempdir) + subprocess.run(["git", "init"]) subprocess.run(["git", "config", "user.email", "dummy@example.com"]) subprocess.run(["git", "config", "user.name", "Dummy User"])