Merge pull request #710 from vladimir-v-diaz/catch_exception_raised_in_windows

Allow 'OSError.ENOENT' exception in test condition (expected in Windows)
This commit is contained in:
Vladimir Diaz 2018-04-26 11:34:47 -04:00 committed by GitHub
commit 08c8bf67ae
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1216,7 +1216,7 @@ def test_6_download_target(self):
self.repository_updater.download_target(targetinfo, bad_destination_directory)
except OSError as e:
self.assertTrue(e.errno == errno.ENAMETOOLONG)
self.assertTrue(e.errno == errno.ENAMETOOLONG or e.errno == errno.ENOENT)
# Test: Invalid arguments.
self.assertRaises(securesystemslib.exceptions.FormatError,