Merge pull request #45666 from terminalmage/salt-jenkins-793

Fix failing pkg integration tests for releases with no '.'
This commit is contained in:
Nicole Thomas 2018-01-24 12:19:09 -05:00 committed by GitHub
commit 9a17405ba6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -28,12 +28,13 @@ class PkgModuleTest(ModuleCase, SaltReturnAssertsMixin):
self.run_function('pkg.refresh_db')
os_release = self.run_function('grains.get', ['osrelease'])
self.pkg = 'htop'
if int(os_release.split('.')[1]) >= 13 and salt.utils.is_darwin():
if salt.utils.is_darwin() and int(os_release.split('.')[1]) >= 13:
self.pkg = 'wget'
elif salt.utils.is_windows:
elif salt.utils.is_windows():
self.pkg = 'putty'
else:
self.pkg = 'htop'
def test_list(self):
'''