Commit Graph

73689 Commits

Author SHA1 Message Date
Eric Radman
158bcbff65 Fix tests that assert CommandExecutionError (#32485)
Trying to assert that an exception was raised using
helper_open.write.assertRaises() is bogus--there is no such method. Use
standard unittest.assertRaises() instead.
2016-09-08 12:39:28 +01:00
Mihai Dincă
8b480167e1 Fix tests (#35693)
* Fix tests/unit/modules/useradd_test.py::UserAddTestCase::test_info

* Fix unit/pyobjects_test.py::MapTests::test_map

* Fix tests/unit/pyobjects_test.py::RendererTests::test_extend

* Fix tests/unit/pyobjects_test.py::RendererTests::test_requisite_implicit_list
2016-09-08 12:39:28 +01:00
Eric Radman
29814f9d43 Skip utils_test if timelib is not installed (#32699)
date_cast() throws a RuntimeError, not an ImportError
2016-09-08 12:39:28 +01:00
Pablo Suárez Hernández
d1d806f893 Fix PortageConfigTestCase in case of portage is not present 2016-09-08 12:39:28 +01:00
Pablo Suárez Hernández
1c260e4bd0 Fix tests to prevent errors when libcloud is not present 2016-09-08 12:39:28 +01:00
twangboy
9f9aa4779c rename darwin_sysctl.py to mac_sysctl.py 2016-09-08 12:28:18 +01:00
abednarik
2cf6f36d89 modules.darwin_sysctl: __virtual__ return err msg.
Updated message in darwin_sysctl module when return False if OS is not OSX.
2016-09-08 12:28:12 +01:00
Mike Place
f74ca15f50 Remove test for file dir behavior
Refs #34809
2016-09-08 11:36:17 +01:00
Eric Radman
c65aefee20 Fix tests that assert CommandExecutionError (#32485)
Trying to assert that an exception was raised using
helper_open.write.assertRaises() is bogus--there is no such method. Use
standard unittest.assertRaises() instead.
2016-09-08 11:36:17 +01:00
twangboy
f8c0b439b8 Fixed more lint 2016-09-08 11:36:17 +01:00
twangboy
63ff731009 Fixed tests 2016-09-08 11:36:17 +01:00
Dmitry Kuzmenko
04b1a4a9ca Fixed use of assert_has_calls in tests.
The method logic was changed in mock-1.1.0.
This mades the use of the method compatible with both <1.1.0 and >=1.1.0
2016-09-08 11:36:17 +01:00
Dmitry Kuzmenko
46e4bb58e5 Fixed LoadAuthTestCase 2016-09-08 11:36:17 +01:00
rallytime
4e9733ad6d Rename dockerio.py unit tests to dockerio_test.py
These tests have never run automatically because of an incorrect file name.

Added a skipIf on these tests as they are currently non-functioning and the
module they're testing has been deprecated.
2016-09-08 11:36:17 +01:00
Pedro Algarvio
ec0cc943e0 Make sure spm tests are picked up by runtests.
Lists in py2 don't have the clear method
2016-09-08 11:36:17 +01:00
kstreee
2605f34849 Fix missing first data in stream when subscribing stream using a function 'read_async'. 2016-09-08 11:36:17 +01:00
Pablo Suárez Hernández
305bab8be0 Fixed _interfaces_ifconfig output for SunOS test 2016-09-08 11:36:17 +01:00
Eric Radman
b5ca02c867 Fix tests that assert CommandExecutionError (#32485)
Trying to assert that an exception was raised using
helper_open.write.assertRaises() is bogus--there is no such method. Use
standard unittest.assertRaises() instead.
2016-09-08 11:36:17 +01:00
Mihai Dincă
1fb6340fef Fix tests (#35693)
* Fix tests/unit/modules/useradd_test.py::UserAddTestCase::test_info

* Fix unit/pyobjects_test.py::MapTests::test_map

* Fix tests/unit/pyobjects_test.py::RendererTests::test_extend

* Fix tests/unit/pyobjects_test.py::RendererTests::test_requisite_implicit_list
2016-09-08 11:36:17 +01:00
Eric Radman
5977f1f54c Skip utils_test if timelib is not installed (#32699)
date_cast() throws a RuntimeError, not an ImportError
2016-09-08 11:36:17 +01:00
Pablo Suárez Hernández
d1b9a4061e Fixing skipped boto tests to prevent errors if boto3 does not exists. 2016-09-08 11:36:17 +01:00
Jonathan Ballet
035a212a9b doc: fix doc formatting for salt.states.mount 2016-09-08 11:53:34 +02:00
Dmitry Kuzmenko
34cfd0112f Print errors to stdout in salt-key as it's done in salt and salt-run. 2016-09-08 12:43:13 +03:00
David Boucha
64a576fc6e add windows core grain test 2016-09-07 21:22:24 -06:00
Mike Place
1e8431f2b8 Allow highstate outputter to show all results
This regressed here: 82a70e015f

The above incorrect assumed that all data flowing into the highstate outputter is expected to be a dictionary. However, looking at _format_host() shows that it does expect to receive multiple types and does handle them accordingly.

I believe that the issue reported in #33915 may be fixed by #35559 instead. This should allow the highstate outputter to display all results instead of stopping after the first one. I would like @terminalmage and @mattglv and possibly @Ch3ll to please confirm this before we get this in.

Resolves #35423
2016-09-08 12:04:32 +09:00
Mike Place
c4ddfe3887 Merge pull request #35954 from morganwillcock/upgrade-on-batteries
win_pkg: Allow minion upgrade on batteries and report launch failure
2016-09-08 10:25:37 +09:00
Mike Place
eac9935b58 Merge pull request #36044 from Ch3LL/add_test_state_event
add salt-run state.event test
2016-09-08 10:23:49 +09:00
Mike Place
70da628018 Merge pull request #36070 from rallytime/fix-36057
Use __utils__ instead of salt.utils.cloud in opennebula driver
2016-09-08 10:18:45 +09:00
Mike Place
b7556a2aeb Merge pull request #36089 from terminalmage/issue35565
Support running git states / remote exec funcs as a different user in Windows
2016-09-08 10:17:22 +09:00
Mike Place
94b7659304 Merge pull request #36129 from terminalmage/pygit2-ssl_verify
pygit2: Prevent traceback on initial gitfs setup
2016-09-08 10:03:25 +09:00
Mike Place
a5b036962e Merge pull request #36091 from UtahDave/36087_pkg_stacktrace
add missing imports and namespace them
2016-09-08 09:15:15 +09:00
David Boucha
453e80c611 Add check for pwd module to the __virtual__ func 2016-09-07 18:03:40 -06:00
David Boucha
277939e0c3 don't stacktrace on import pwd on Windows 2016-09-07 18:03:40 -06:00
Erik Johnson
640f0c17c6 pygit2: Prevent traceback on initial gitfs setup
Newer pygit2 releases require that this value be a string, they will not
accept a bool here.
2016-09-07 17:12:05 -05:00
Nicole Thomas
d0bfbe8820 Fix Windows salt-master (#36119)
The salt-master on Windows was broken by PR #35703 due to the change in
how the ReqServer object was started in a new process. The new way
failed to correctly pickle/unpickle the args/kwargs. To fix this, we
use `__setstate__` and `__getstate__` similar to how other objects in
the same file handle it (such as the `Maintenance` object).

Signed-off-by: Sergey Kizunov <sergey.kizunov@ni.com>
2016-09-07 16:02:45 -06:00
Nicole Thomas
760da9df6a Merge pull request #36117 from rallytime/merge-carbon
[carbon] Merge forward from 2016.3 to carbon
2016-09-07 16:01:46 -06:00
Nicole Thomas
7cdbc546f1 Back-port #36062 to 2015.8 (#36118)
* Comment all lines in the minion config file

* Add unit tests to check for all files in conf/ to be commented out

* Make sure cont/cloud.profiles file is commented out

Matches the cloud.providers file format and other sample config files.

* Add unit tests for sample files in cloud.profiles.d, cloud.providers.d,
and cloud.maps.d

* Make sure all sample config files in cloud.maps.d are commented out

* Make sure all sample config files in cloud.profiles.d are commented out
2016-09-07 16:01:34 -06:00
rallytime
07172cf371 Add some unit tests for the jid_queue functionality in minion.py
Refs #35172 and #28785
2016-09-07 14:15:35 -06:00
twangboy
da2dded3c3 Use /etc instead of /root 2016-09-07 12:34:33 -06:00
twangboy
b4112247a4 Fix test not starting, skip broken functions 2016-09-07 12:01:38 -06:00
Erik Johnson
796156c5f5 Add attribution 2016-09-07 11:17:56 -05:00
rallytime
40d0def479 Merge branch '2016.3' into 'carbon'
Conflicts:
  - salt/states/archive.py
2016-09-07 10:11:36 -06:00
Ch3LL
ee398a94b6 fix pylint 2016-09-07 10:05:44 -06:00
twangboy
dc1988add5 fix download when requests not present 2016-09-07 09:59:51 -06:00
Erik Johnson
2e56527ead Move command logging to before win_runas
With the addition of runas for Windows in 2016.3.0, commands run using
Windows runas would not be logged at all, as we would return from the
_run() function before we got to the line where this information was
logged. This commit moves the command logging up to before we enter the
if block where the win_runas code would be executed, restoring the
prior logging behavior.
2016-09-07 10:36:13 -05:00
rallytime
de4f77cb68 Fixup failing test: need to mock __utils__ instead of salt.utils.cloud call 2016-09-07 08:46:47 -06:00
Mike Place
45ba2e806b Merge pull request #35923 from kstreee/fix-cli-stalling
Fixes a bug that Ctrl-c not working on Salt CLI.
2016-09-07 20:47:50 +09:00
Mike Place
6460412b1c Merge pull request #36042 from jfindlay/parallels
add functions to parallels execution module
2016-09-07 15:09:10 +09:00
Mike Place
48dc5ad4ee Merge pull request #36078 from thatch45/failhard_test
Failhard test=True fix
2016-09-07 14:10:35 +09:00
Mike Place
4e609a2962 Merge pull request #36062 from rallytime/fix-36045
Add test to catch sample config files that are not commented out
2016-09-07 10:30:30 +09:00