diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /app-admin/salt/files/salt-2015.8.0-remove-buggy-tests.patch |
reinit the tree, so we can have metadata
Diffstat (limited to 'app-admin/salt/files/salt-2015.8.0-remove-buggy-tests.patch')
-rw-r--r-- | app-admin/salt/files/salt-2015.8.0-remove-buggy-tests.patch | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/app-admin/salt/files/salt-2015.8.0-remove-buggy-tests.patch b/app-admin/salt/files/salt-2015.8.0-remove-buggy-tests.patch new file mode 100644 index 000000000000..92ab0624e595 --- /dev/null +++ b/app-admin/salt/files/salt-2015.8.0-remove-buggy-tests.patch @@ -0,0 +1,56 @@ +diff --git a/tests/unit/modules/mount_test.py b/tests/unit/modules/mount_test.py +index 282539d..c88a7a8 100644 +--- a/tests/unit/modules/mount_test.py ++++ b/tests/unit/modules/mount_test.py +@@ -103,12 +103,6 @@ class MountTestCase(TestCase): + self.assertTrue(mount.rm_fstab('name', 'device')) + + mock = MagicMock(return_value={'name': 'name'}) +- with patch.object(mount, 'fstab', mock): +- with patch('salt.utils.fopen', mock_open()) as m_open: +- helper_open = m_open() +- helper_open.write.assertRaises(CommandExecutionError, +- mount.rm_fstab, +- config=None) + + def test_set_fstab(self): + ''' +@@ -143,12 +137,6 @@ class MountTestCase(TestCase): + self.assertTrue(mount.rm_automaster('name', 'device')) + + mock = MagicMock(return_value={'name': 'name'}) +- with patch.object(mount, 'fstab', mock): +- with patch('salt.utils.fopen', mock_open()) as m_open: +- helper_open = m_open() +- helper_open.write.assertRaises(CommandExecutionError, +- mount.rm_automaster, +- 'name', 'device') + + def test_set_automaster(self): + ''' +diff --git a/tests/unit/modules/puppet_test.py b/tests/unit/modules/puppet_test.py +index 6a43fd4..3be039c 100644 +--- a/tests/unit/modules/puppet_test.py ++++ b/tests/unit/modules/puppet_test.py +@@ -91,10 +91,6 @@ class PuppetTestCase(TestCase): + with patch('salt.utils.fopen', mock_open()): + self.assertTrue(puppet.disable()) + +- with patch('salt.utils.fopen', mock_open()) as m_open: +- helper_open = m_open() +- helper_open.write.assertRaises(CommandExecutionError, +- puppet.disable) + + def test_status(self): + ''' +@@ -154,10 +150,6 @@ class PuppetTestCase(TestCase): + mock_open(read_data="resources: 1")): + self.assertDictEqual(puppet.summary(), {'resources': 1}) + +- with patch('salt.utils.fopen', mock_open()) as m_open: +- helper_open = m_open() +- helper_open.write.assertRaises(CommandExecutionError, +- puppet.summary) + + def test_plugin_sync(self): + ''' |