mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Merge pull request #45337 from twangboy/win_fix_test_core
Fix `unit.grains.test_core` for Windows
This commit is contained in:
commit
227cdbda70
@ -499,6 +499,7 @@ PATCHLEVEL = 3
|
||||
self.assertEqual(_grains.get('iscsi_iqn'),
|
||||
['iqn.1991-05.com.microsoft:simon-x1'])
|
||||
|
||||
@skipIf(salt.utils.platform.is_windows(), 'System is Windows')
|
||||
def test_aix_iscsi_iqn_grains(self):
|
||||
cmd_run_mock = MagicMock(
|
||||
return_value='initiator_name iqn.localhost.hostid.7f000001'
|
||||
@ -515,6 +516,7 @@ PATCHLEVEL = 3
|
||||
['iqn.localhost.hostid.7f000001'])
|
||||
|
||||
@skipIf(salt.utils.platform.is_darwin(), 'MacOSX iscsi grains not supported')
|
||||
@skipIf(salt.utils.platform.is_windows(), 'System is Windows')
|
||||
def test_linux_iscsi_iqn_grains(self):
|
||||
_iscsi_file = '## DO NOT EDIT OR REMOVE THIS FILE!\n' \
|
||||
'## If you remove this file, the iSCSI daemon will not start.\n' \
|
||||
@ -618,6 +620,7 @@ SwapTotal: 4789244 kB'''
|
||||
self.assertEqual(os_grains.get('mem_total'), 15895)
|
||||
self.assertEqual(os_grains.get('swap_total'), 4676)
|
||||
|
||||
@skipIf(salt.utils.platform.is_windows(), 'System is Windows')
|
||||
def test_bsd_memdata(self):
|
||||
'''
|
||||
Test to memdata on *BSD systems
|
||||
@ -687,6 +690,7 @@ SwapTotal: 4789244 kB'''
|
||||
self.assertEqual(os_grains.get('mem_total'), 2023)
|
||||
self.assertEqual(os_grains.get('swap_total'), 400)
|
||||
|
||||
@skipIf(salt.utils.platform.is_windows(), 'System is Windows')
|
||||
def test_docker_virtual(self):
|
||||
'''
|
||||
Test if OS grains are parsed correctly in Ubuntu Xenial Xerus
|
||||
|
Loading…
Reference in New Issue
Block a user