Skip to content

Commit

Permalink
Add test for spawn when exe is missing. Ref #3.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Jul 5, 2020
1 parent 76d53a8 commit f3b4a99
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions distutils/tests/test_spawn.py
Expand Up @@ -126,6 +126,11 @@ def test_find_executable(self):
rv = find_executable(program)
self.assertEqual(rv, filename)

def test_spawn_missing_exe(self):
with self.assertRaises(DistutilsExecError) as ctx:
spawn(['does-not-exist'])
assert 'command does-no-exist failed' in str(ctx)


def test_suite():
return unittest.makeSuite(SpawnTestCase)
Expand Down

0 comments on commit f3b4a99

Please sign in to comment.