Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent afa5754 commit e40fc2cCopy full SHA for e40fc2c
test/test_git.py
@@ -260,13 +260,9 @@ def test_it_ignores_false_kwargs(self, git):
260
self.assertTrue("pass_this_kwarg" not in git.call_args[1])
261
262
def test_it_raises_proper_exception_with_output_stream(self):
263
- tmp_file = TemporaryFile()
264
- self.assertRaises(
265
- GitCommandError,
266
- self.git.checkout,
267
- "non-existent-branch",
268
- output_stream=tmp_file,
269
- )
+ with TemporaryFile() as tmp_file:
+ with self.assertRaises(GitCommandError):
+ self.git.checkout("non-existent-branch", output_stream=tmp_file)
270
271
def test_it_accepts_environment_variables(self):
272
filename = fixture_path("ls_tree_empty")
0 commit comments