Commit Graph

641 Commits

Author SHA1 Message Date
Andrew Pashkin
7d59f7a6c6 Make possible to reference pillars, that come before current pillar in the top file 2017-07-12 19:03:05 +03:00
rallytime
7e0c099ab3 Add get_driver function used with libcloud modules to doc exception list
Fixes failing valid_docs test in develop
2017-07-11 09:13:38 -06:00
rallytime
8d960d463a Merge branch '2017.7' into 'develop'
Conflicts:
  - salt/grains/core.py
2017-07-06 17:42:30 -06:00
Gareth J. Greenaway
a34970b45b Back porting the fix for 2017.7 that ensures the order of the names parameter. 2017-07-06 12:12:50 -07:00
Erik Johnson
d15f7ded82 Add integration test for 42116 2017-07-05 11:07:38 -05:00
Erik Johnson
9a268949e3 Add integration test for 42116 2017-07-05 00:48:50 -05:00
rallytime
e512a29f08 Merge branch '2017.7' into 'develop'
Conflicts:
  - salt/modules/state.py
  - salt/modules/yumpkg.py
  - salt/modules/zypper.py
  - salt/states/pkg.py
  - salt/version.py
  - tests/unit/config/test_config.py
  - tests/unit/modules/test_zypper.py
2017-06-28 11:31:53 -06:00
Ch3LL
73271ce94d Add vmware test to check new disk on seperate datastore 2017-06-23 18:36:50 -04:00
Dmitry Kuzmenko
dd4273e268 Temporary POC: disable runtests log handler for Py3 tests. 2017-06-19 22:26:06 +03:00
rallytime
7fef4cf38f Merge branch '2017.7' into 'develop'
Conflicts:
  - salt/engines/slack.py
2017-06-15 10:57:27 -06:00
Erik Johnson
5c970d81e5 Fix runtests_helpers.modules_available when multiple modules passed
tests.support.helpers passes the single-asterisk tuple of args as
individual arguments to runtest_helpers.modules_available. This breaks
tests which pass more than one argument to the requires_salt_modules
decorator.

This has been fixed by making runtests_helpers.modules_available accept
an arbitrary number of args via using a single-asterisk.
2017-06-14 13:16:30 -05:00
rallytime
2cb4f2baa9 Merge branch 'nitrogen' into 'develop'
Conflicts:
  - salt/states/keystone.py
2017-06-06 12:50:35 -06:00
Nicole Thomas
be0683de78 Merge pull request #41595 from gtmanfred/nitrogen
Make sure runtests_engine is ASCII text
2017-06-05 20:43:50 -06:00
Daniel Wallace
f309bae8b4 Make sure runtests_engine is ASCII text
If this is has any unicode characters in it, it won't load on systems that do
not default to a unicode locale.

find . -type f | while read line; do ret=$(file $line); if [[ $ret == *UTF-8* && $line == *.py ]]; then echo $line; fi; done

The above will list all files that have unicode characters in it and won't load
with locale set to C or POSIX
2017-06-05 17:30:28 -06:00
rallytime
833b2145c4 Merge branch 'nitrogen' into 'develop'
No conflicts.
2017-06-01 17:15:36 -06:00
Dmitry Kuzmenko
fef0e0ea67 Catch errors on socket.shutdown.
It throws an exception if the socket wasn't connected.
2017-06-01 16:49:57 +03:00
rallytime
57166fd892 Merge branch 'nitrogen' into 'develop'
No conflicts.
2017-05-24 15:30:44 -06:00
rallytime
616ac7289b Merge branch '2016.11' into 'nitrogen'
Conflicts:
  - salt/config/__init__.py
  - salt/modules/elasticsearch.py
  - tests/integration/__init__.py
2017-05-23 10:36:41 -06:00
Erik Johnson
772167306c Merge pull request #41015 from gtmanfred/docker
Allow docker.call to run as non-root user
2017-05-06 01:21:05 -05:00
C. R. Oldham
3be90cc9f4 Rescue proxy_auto_tests PR from git rebase hell 2017-05-05 17:04:00 -06:00
rallytime
01a012bbdf Merge branch 'nitrogen' into 'develop'
No conflicts.
2017-05-05 10:12:18 -06:00
twangboy
20da5f5d4b Add software def for putty 2017-05-04 15:16:21 -06:00
rallytime
319dc45c1d Merge branch 'nitrogen' into 'develop'
Conflicts:
  - salt/runners/saltutil.py
2017-05-04 11:51:32 -06:00
Nicole Thomas
2bf02fad81 Merge pull request #41050 from terminalmage/git_pillar-tests
Fix git_pillar integration tests on Arch
2017-05-03 16:53:31 -06:00
Erik Johnson
a94d081004 Add check for git-http-backend
This allows for more graceful test failures when the libexec dir is
different from what the test class determines it should be.
2017-05-03 15:16:16 -05:00
Daniel Wallace
948830a4cb add tests 2017-05-02 16:16:51 -06:00
twangboy
3ef4734d0e Increase timeout for Windows 2017-05-02 11:37:01 -06:00
rallytime
ecb962cdee Merge branch 'nitrogen' into 'develop'
Conflicts:
  - salt/runners/saltutil.py
2017-05-02 09:00:22 -06:00
Mike Place
f766c97e26 Merge pull request #40777 from terminalmage/issue39349
Add git_pillar integration tests
2017-05-01 13:51:19 -06:00
Erik Johnson
9f27f362ca Add HTTP git_pillar integration tests for pygit2
Also work around ssh auth issues in Ubuntu
2017-04-27 18:20:18 -05:00
Erik Johnson
9e6361c6c8 Add GitPython HTTP git_pillar tests 2017-04-27 00:48:24 -05:00
Daniel Wallace
0ee3ecf464 Add tests for Zookeeper states 2017-04-24 18:01:16 -06:00
rallytime
bad421be66 Update managed.sls test file: osmajorrelease grain is an int now
We need to make the comparison in the file to `7` instead of `'7'`,
otherwise the state doesn't execute correctly and the test_pkgrepo
test will fail because the state didn't run.
2017-04-20 12:27:45 -06:00
Erik Johnson
e03698fbeb Add git_pillar integration tests
This also adds a new section to the runtests.py so that ext_pillar
integration tests can be run separately.
2017-04-20 03:51:08 -05:00
Erik Johnson
7cef07b0d9 Remove legacy git_pillar tests
Also remove git_pillar configuration from the test suite's master
configuration file.
2017-04-20 03:51:08 -05:00
Pedro Algarvio
2d32fab65b
Don't instantiate the log handler if unable to connect to server 2017-04-05 23:29:13 +01:00
Nicole Thomas
4d7871e4d7 Merge pull request #40494 from rallytime/merge-develop
[develop] Merge forward from 2016.11 to develop
2017-04-05 14:15:05 -06:00
rallytime
71f3c73150 Merge branch '2016.11' into 'develop'
Conflicts:
  - salt/template.py
  - salt/utils/pycrypto.py
  - tests/integration/modules/test_state.py
  - tests/unit/states/test_artifactory.py
  - tests/unit/test_template.py
2017-04-05 13:02:14 -06:00
Pedro Algarvio
94d944da52
Limit the size of the log records queue 2017-04-05 16:38:05 +01:00
Pedro Algarvio
0c61c151c3
Fix state logic 2017-04-05 02:07:54 +01:00
Pedro Algarvio
cd1f7ba629
Let's use the system temp dir as it was to see if it fixes the test failure 2017-04-05 00:34:39 +01:00
Pedro Algarvio
dcf0a55daf
Use the test run temporary path, not the system temporary path 2017-04-04 18:58:21 +01:00
Pedro Algarvio
9bbfd6605c
Fix state files temporary path 2017-04-04 18:58:21 +01:00
Pedro Algarvio
9af2ca8823
No need to load all modules docs.
This should reduce memory usage as well as speeding up the decorator
2017-04-04 18:04:38 +01:00
Mike Place
6056ee302a Merge pull request #40339 from s0undt3ch/features/py3-pt2
[WIP] Move unit tests which were in integration tests - More py3 and mocking fixes
2017-04-04 10:21:46 -06:00
Mike Place
d254b96498 Merge pull request #40471 from tonybaloney/libcloud_dns_kwargs
Update to libcloud_dns module to allow custom kwargs for DNS drivers
2017-04-04 10:12:44 -06:00
rallytime
ede4c28887 Group checks for failhard setting in () in state.check_failhard function
Fixes #38683

When two states combine the `require`, `failhard`, and `order` options,
the `order` option should be ignored because `require` is present. Then
the `failhard` option should make the state run fail.

The check for "failhard" in the `check_failhard` function in the state
compiler was too broad. We want "failhard" to be true AND tag to be in
the `running` dict. Without the parens around the first OR statement,
we were bypassing the AND requirement because failhard was found.

Since the second state's tag was not found in the running dict, the state
run stacktraces on a KeyError.
2017-04-03 14:41:54 -06:00
Pedro Algarvio
a013f792c6
We actually need to fix the pip state to recognize new/deprecated options 2017-04-01 14:22:52 +01:00
Pedro Algarvio
22c753afba
Disable pip wheel usage for this test.
The pip cache dir will be owned by root and not the user created.
Revisit this issue ASAP.
2017-04-01 14:22:52 +01:00
Anthony Shaw
eb8ab0d75a
add tests to show broken functionlity reported in bug report 2017-04-01 09:21:25 +11:00
Ch3LL
5cd34a9083 finish the tests 2017-03-30 15:57:53 -06:00
Ch3LL
cbb6eca2cf initial commit for vmware cloud test 2017-03-28 16:23:59 -06:00
Erik Johnson
5ad476936d Overhaul Docker support
This does the following:

- Splits states for container/volume/image/network management into four
  separate state modules.

- Preserves backward compatibility by making ``docker.image_present``
  invoke ``docker_image.present``, etc.

- Changes how Salt detects that a container needs to be replaced.
  Instead of comparing each passed argument to the named container's
  configuration, it creates a temporary container, and compares that
  container to the named container. If the two differ, then the older
  container is removed, and the new one is renamed and started, becoming
  the named container.

- Removes the unit tests for container management and replaces them with
  integration tests.

- Adds unit tests for the new salt.utils.docker
2017-03-21 16:53:19 -05:00
Pedro Algarvio
42065350f1
Catch and handle tornado.iostream.StreamClosedError exceptions 2017-03-09 19:29:16 +00:00
Pedro Algarvio
712b81e0c1
supervisor does not run against py3. Use pep8 for the tests. 2017-03-08 18:34:32 +00:00
Pedro Algarvio
adacf4cc28
Don't expect any ordering from sets!!!!! 2017-03-03 18:31:11 +00:00
Pedro Algarvio
31df825a1c
Set the ssh_log_file relative 2017-03-02 19:56:06 +00:00
Pedro Algarvio
fc501e93ac
Remove deprecated options 2017-03-02 19:56:05 +00:00
Mike Place
33e40c94e4
Fix docs test for #39753 2017-03-01 09:06:17 -07:00
Pedro Algarvio
08804932c3
Using pytest start_daemon 2017-02-28 22:52:48 +00:00
Nicole Thomas
8809d33674 Merge pull request #39701 from rallytime/merge-develop
[develop] Merge forward from 2016.11 to develop
2017-02-28 12:50:10 -07:00
Erik Johnson
7b958fb389 Add options to skip fileserver/git_pillar preflight checks
This commit also modifies the master config for the test suite to use
this new option, so that a missing GitPython/Pygit2 will not crash the
test suite's master. This should make the test suite run smoother by
only negatively impacting those tests which require the pillar data
provided by git_pillar, when a valid provider is not available.
2017-02-27 20:21:53 -06:00
rallytime
b4366103a6 Merge branch '2016.11' into 'develop'
Conflicts:
  - .pylintrc
  - .testing.pylintrc
  - salt/fileclient.py
  - salt/minion.py
  - salt/modules/docker.py
  - salt/modules/win_iis.py
  - salt/states/docker.py
  - salt/states/file.py
  - salt/utils/__init__.py
  - tests/integration/modules/test_sysmod.py
2017-02-27 15:11:37 -07:00
Erik Johnson
5a3c099e4f Rewrite the tests_valid_docs test
This uses a function in the runtests_helpers custom module to perform
all the logic, and only returns what failed the test. This saves us from
having to return the entire contents of sys.doc (as well as log all of
the function calls), and also removes the need to run sys.doc in batches
to get around the "max message size" issue.
2017-02-26 12:21:00 -06:00
Pedro Algarvio
26b17fb044
Make sure the minion sync's modules/states/grains/etc when starting 2017-02-13 10:18:57 +00:00
Erik Johnson
4e577e697d Switch to non-legacy git_pillar syntax in test suite 2017-02-12 15:12:49 -06:00
rallytime
9ad362fbde Merge branch '2016.11' into 'develop'
Conflicts:
  - salt/states/kapacitor.py
2017-01-03 10:17:18 -05:00
twangboy
e96bfe8fa2 Change OSX/OS X to macOS where possible 2016-12-28 14:49:46 -07:00
Elias Wulcan
266e0a465c Fixed nested orchestrate not respecting failures
Client was only setting success to false if the function called raised
an exception. This commit changes it to verify the content of return
value with check_state_result
2016-12-19 10:29:05 +01:00
Elias Wulcan
5f9b6c8ba4 Fixed nested orchestrate not respecting failures
Client was only setting success to false if the function called raised
an exception. This commit changes it to verify the content of return
value with check_state_result
2016-12-15 10:33:25 +01:00
Seth House
15826ca207 Add integration test for checking the type of the __sls__ field
We should add a bunch more of these for other fields. Or we should just
use Typings to define the return from the state functions. ^_^
2016-12-05 14:08:20 -07:00
rallytime
6479a22c1d Merge branch '2016.11' into 'develop'
Conflicts:
  - salt/modules/napalm_network.py
2016-11-18 07:50:16 -07:00
rallytime
d5a7ef6ca8 Merge branch '2016.3' into '2016.11'
No conflicts.
2016-11-17 10:37:42 -07:00
Ch3LL
9ef41dcdfc change size and image of joyent profile 2016-11-16 11:54:21 -07:00
Eric Radman
4cd92980d8 Use 'driver' instead of 'provider' in test cloud configs (#37547)
Running the tests currently provokes a warning from
salt/config/__init__.py:│2275 ("'provider' will be
deprecated in the Nitrogen release")
2016-11-08 09:50:39 -07:00
Ethan Devenport
21e24a8125 Cloud API v3 updates including:
* Added server availability zone parameter.
* Added volume availability zone parameters.
* Added NAT parameter for private NIC.
* Updated documentation.
2016-11-01 21:37:53 +00:00
Mike Place
afd3dc3807
Merge branch '2016.3' into 2016_3_carbon 2016-10-26 14:08:03 +09:00
Eric Radman
3829b7592f Update configuration examples for Joyent
* Fix typo in profile example ('private_key' listed twice)
* Reflect Joyent's current new naming convention for VM sizes
* Update docs with modern images that are officially supported by Joyent
* Refresh example output of --list-sizes and --list-images
2016-10-25 10:43:32 -06:00
rallytime
70851807bd Merge branch 'carbon' into 'develop'
Conflicts:
  - salt/modules/status.py
2016-10-24 09:35:00 -06:00
Eric Radman
30146115ee Update configuration examples for Joyent (#37153)
* Fix typo in profile example ('private_key' listed twice)
* Reflect Joyent's current new naming convention for VM sizes
* Update docs with modern images that are officially supported by Joyent
* Refresh example output of --list-sizes and --list-images
2016-10-22 07:58:46 -06:00
rallytime
caa8fc9169 Merge branch '2016.3' into 'carbon'
Conflicts:
  - pkg/deb/salt-api.service
  - pkg/deb/salt-master.service
  - salt/client/__init__.py
  - salt/fileclient.py
  - salt/modules/cp.py
  - salt/modules/status.py
  - tests/integration/__init__.py
  - tests/integration/modules/cp.py
2016-10-21 15:50:03 -06:00
Nicole Thomas
2bc5dedd06 Allow the minion test daemons a couple of tries to connect to the master (#37150)
When running the tests with the tcp transport, we are not as forgiving
with the minion connection process as we are in ZMQ. In ZMQ, we attempt
to connect to the master. If it isn't up yet, we wait and try again. In
TCP, we try to connect to the master once, realize it's not up (because
the master process takes longer to spin up than the minions) and crash
and bail out.

This just gives the master a little more time to come up by having the
minions try to connect a couple more times.
2016-10-21 14:50:39 -06:00
Megan Wilhite
f22c686b34 fix digital ocean image name in profile (#37126)
* fix digital ocean image name in profile

* remove skip and fix test
2016-10-20 16:08:50 -06:00
Mike Place
53f1523cb8 Merge pull request #36790 from cachedout/pr-36727
Merge forward carbon to develop
2016-10-05 23:57:23 +09:00
Ethan Moore
2ad701784a add integration tests for retry state option 2016-10-04 20:06:59 +00:00
rallytime
616aafa398 Merge branch '2016.3' into 'carbon'
No conflicts.
2016-09-29 11:47:48 -06:00
rallytime
3e4ac617d3 Merge branch '2015.8' into '2016.3'
Conflicts:
  - tests/integration/cli/grains.py
  - tests/integration/files/file/base/issue-2068-template-str-no-dot.sls
  - tests/integration/files/file/base/issue-2068-template-str.sls
  - tests/integration/modules/pip.py
2016-09-29 09:15:26 -06:00
Mike Place
f4906fe771
Fix test not to rely on external resources
We can still model the original issue without needing to call all the way out to pypi to do it.
2016-09-29 12:35:02 +09:00
Erik Johnson
aab02f28b4 Ensure we have a test venv created using virtualenv < 13.0
The test that runs these states is testing for behavior that was
obsoleted by virtualenv 13.0. Ensure that we have older virtualenv
available, and then create a venv with that older version. Use the
2nd virtualenv to attempt the "weird" install.
2016-09-19 14:27:30 -06:00
Erik Johnson
f4dded464c Ensure we have a test venv created using virtualenv < 13.0
The test that runs these states is testing for behavior that was
obsoleted by virtualenv 13.0. Ensure that we have older virtualenv
available, and then create a venv with that older version. Use the
2nd virtualenv to attempt the "weird" install.
2016-09-14 22:42:39 -05:00
Daniel Wallace
1c31d5e464 add keystone state integration tests
fix api_version for using connection_args
2016-09-09 17:14:44 -05:00
rallytime
40d0def479 Merge branch '2016.3' into 'carbon'
Conflicts:
  - salt/states/archive.py
2016-09-07 10:11:36 -06:00
Thomas S Hatch
40081176af Merge pull request #34529 from Ch3LL/add_skip_verify_archive
Add skip_verify for archive.extracted
2016-09-06 15:05:31 -06:00
Megan Wilhite
8f7df39181 add onfail multiple test (#35968) 2016-08-31 20:40:36 -06:00
Pedro Algarvio
f842ddd525 OSX testsuite fixes (#35948)
* OSX is a bit more restrictive on getting the process information

* OSX says the sockets aren't connected, which is weird, but...

* Close the sockets on OSX
2016-08-31 13:09:51 -06:00
Thomas S Hatch
407d164752 Add tests for #22558 (#35915) 2016-08-30 17:13:12 -06:00
Mike Place
6725cd458c Merge pull request #35156 from twangboy/int_states_file
Fix integration tests for file state on Windows
2016-08-30 17:45:17 +09:00
twangboy
b7263d24b5 Additional cachedout recommendations 2016-08-29 15:22:17 -06:00
twangboy
c9acbfee38 Fix jinja 2016-08-29 14:53:41 -06:00
twangboy
cd2ce9fb01 Use Jinja instead of seperate files 2016-08-29 14:53:41 -06:00
twangboy
56180cf09d Fix/Skip tests for windows 2016-08-29 14:53:41 -06:00
Justin Anderson
ab7e511fd1 Change osmajorrelease back to str (#35858) 2016-08-29 11:24:20 -06:00
rallytime
b80ef26cf2 Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/cli/batch.py
  - salt/minion.py
  - salt/modules/cassandra_cql.py
  - salt/modules/rsync.py
2016-08-23 10:44:55 -06:00
rallytime
1d819d7cc2 Merge branch '2015.8' into '2016.3'
No conflicts.
2016-08-22 09:29:13 -06:00
Mike Place
6e1dcb94ec Account for differences in output 2016-08-22 20:54:03 +09:00
Mike Place
e7405258d4 Merge pull request #35499 from cro/returner_self_destruct
Returner self destruct
2016-08-20 11:42:03 +09:00
rallytime
30f42d5352 Write test for multiple unless commands where 1st cmd passes and 2nd fails
This is a regression integration test for #35384, which was fixed by #35545,
and back-ported to the 2015.8 branch in #35566.
2016-08-18 11:04:08 -06:00
Mike Place
9279d6b6eb Merge pull request #35496 from StackPointCloud/profitbricks-cloud-improvements
ProfitBricks cloud provider features and improvements
2016-08-18 09:39:02 +09:00
Ethan Devenport
de42b0135c Added new features and improvements to the ProfitBricks provider including:
* Refactored LAN and NIC provisioning to use a more efficient composite server request.
* Added support for new INTEL_XEON and AMD_OPTERON CPU family types.
* Allow additional data volumes can be created and attached to servers.
* Added public and private network firewall rules.
* Added preliminary support for loadbalancers CLI functions.
* Corrected ProfitBricks name topic index.
* Updated ProfitBricks provider documentation.
* Updated provider integration test configs.
* PEP8 clean up.
2016-08-16 20:07:42 +00:00
rallytime
49179ac401 Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/modules/win_pkg.py
  - tests/integration/files/conf/master
2016-08-16 12:52:20 -06:00
rallytime
c6c82be1de Merge branch '2015.8' into '2016.3'
Conflicts:
  - salt/cloud/deploy/bootstrap-salt.sh
2016-08-16 11:02:05 -06:00
C. R. Oldham
9ff22fd4f1 WIP MySQL returner archiver 2016-08-16 10:33:26 -06:00
rallytime
1fe0b69a6c Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/modules/blockdev.py
  - salt/modules/ddns.py
  - salt/modules/inspectlib/collector.py
  - salt/modules/linux_sysctl.py
  - salt/modules/status.py
  - salt/modules/x509.py
  - salt/utils/process.py
  - salt/utils/verify.py
  - tests/integration/__init__.py
  - tests/integration/modules/state.py
  - tests/integration/states/cmd.py
2016-08-12 16:21:58 -06:00
Mike Place
fc0d5878bc Set file_recv on test master 2016-08-12 19:08:27 +09:00
rallytime
a651962e95 Merge branch '2015.8' into '2016.3'
No conflicts.
2016-08-10 10:02:03 -06:00
Erik Johnson
243909f39d file.recurse: Do not convert octal mode string to int (#35309)
* Add integration test for #34945

* file.recurse: Do not convert octal mode string to int

When we run file.makedirs_perms to create the dest directory, we pass
through the mode to file.check_perms. However, file.check_perms expects
an octal string, not an int. This causes the initial directory to be
chmod'ed to the wrong mode. When there are files in the source
directory, file.recurse will invoke the file.directory state to manage
files/dirs in that directory, and this ends up correcting the mode as we
simply pass the dir_mode to it. However, when there are only directories
in the source directory, this never happens and the incorrect mode
remains on the destination directory.

Fixes #34945.
2016-08-09 13:02:26 -06:00
Mike Place
66127f277b Merge pull request #35005 from twangboy/int_tests_state
Fix state execution module integration tests for Windows
2016-07-28 13:37:54 -06:00
twangboy
d409a51bec Add missing state file for windows 2016-07-27 15:23:51 -07:00
twangboy
47fb8379d7 Remove hosts and aliases from sub_minion conf 2016-07-26 16:07:55 -06:00
twangboy
d7800567f5 Fix hosts integration test 2016-07-26 16:00:07 -06:00
Ch3LL
617f5680e4 add windows path and add custom tar 2016-07-22 17:51:41 -06:00
Mike Place
d85aca1f7a Merge branch 'develop' into int_tests_interfaces 2016-07-21 12:26:21 -06:00
Mike Place
5f5d7193b0 Add interface to all configs
This got removed during the attempt to make the tests run on Windows.

I added them everywhere even though that's not strictly necessary.

Without these set on the master and sub_master, Windows will throw
erorrs because the networking stack will decide that anything that's
bound to 0.0.0.0 represents an extestential threat to any socket that
attempts to *connect* to one of those ports. (For...reasons.)
2016-07-20 10:00:31 -06:00
twangboy
4e56d28993 Add tcp_master settings to both masters 2016-07-20 10:00:31 -06:00
twangboy
3833c008b2 Cleans up config parameters 2016-07-20 10:00:30 -06:00
twangboy
c1ae2537f1 Remove configuration from configs 2016-07-20 10:00:30 -06:00
twangboy
79b5be6989 Add more descriptive report for interactive mode 2016-07-20 10:00:30 -06:00
twangboy
54647eb7d8 Fix mem leak caused by pki_dir 2016-07-20 10:00:30 -06:00
twangboy
7f3f15378e Make additional changes to master configs 2016-07-20 10:00:30 -06:00
twangboy
a33c5c15da Fix master and sub_minion configs 2016-07-20 10:00:30 -06:00
twangboy
f55ba87bee Fix configs, remove default values 2016-07-20 10:00:30 -06:00
twangboy
9b14dc0a6e Add Pedro's suggestions 2016-07-20 10:00:30 -06:00
twangboy
1805630fdc Fix integration tests on windows 2016-07-20 10:00:29 -06:00
twangboy
f7fb4985c4 Add Pedro's suggestions 2016-07-20 10:00:29 -06:00
twangboy
5bcb27e477 Fix integration tests on windows 2016-07-20 10:00:29 -06:00
Bo Maryniuk
3cb6940904 Bugfix: access 'osmajorrelease' as an integer value 2016-07-18 17:14:57 +02:00
Mike Place
4c75d4f92b Integration test for grains data in templatized files (#34487)
Refs #34433
2016-07-07 12:16:35 -04:00
rallytime
e4a8c585d0 Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/states/pkg.py
2016-07-05 13:11:32 -06:00
rallytime
8398de0baf Merge branch '2015.8' into '2016.3'
No conflicts.
2016-06-30 16:08:57 -06:00
Mike Place
45b8fb10d7 Merge pull request #34373 from jtand/network_state_integration_test
Network state integration test
2016-06-30 08:05:44 -07:00
Erik Johnson
d6af1de0b7 Optimize pkg integration tests and add a couple new tests (#34377)
* Remove redundant usage of destructiveTest decorator

* Remove unnecessary SLS file

This simple state can be run using run_state

* Explicitly order tests

* Use run_state instead of invoking state.sls

* Ensure only one refresh_db done during pkg integration tests

* Add pkg.latest test for package without an epoch

* Optimize pkg.latest_version usage in pkg integration tests

* Clarify outcome when only_upgrade is used

* Add pkg.latest test with only_upgrade=True
2016-06-30 10:48:22 -04:00
rallytime
3149da1bcc Merge branch '2015.8' into '2016.3'
No conflicts.
2016-06-29 16:16:46 -06:00
Justin Anderson
1d24053e36 network.system sls file 2016-06-29 14:31:46 -06:00
Justin Anderson
4a9e6af542 network.routes sls file 2016-06-29 14:31:07 -06:00
Justin Anderson
76c90b2ef6 network.managed sls file 2016-06-29 14:30:23 -06:00
Nicole Thomas
94e094652c Back-port #34324 to 2015.8 (#34344)
* Add test to match against custom grains

* Lint

* Forgot to add custom grain
2016-06-28 16:35:32 -04:00
Mike Place
e81bd6ee94 Test custom grains matcher (#34324)
* Add test to match against custom grains

* Lint

* Forgot to add custom grain
2016-06-28 12:17:14 -04:00
rallytime
9220ea0729 Merge branch '2016.3' into 'develop'
Conflicts:
  - doc/conf.py
  - salt/minion.py
  - salt/modules/mac_brew.py
  - salt/modules/pkgng.py
  - salt/states/apache_module.py
  - salt/states/ini_manage.py
  - salt/states/win_servermanager.py
2016-06-02 10:13:34 -04:00
Justin Findlay
8295b48459 test.integration: use hard /tmp on MacOS
Otherwise, the tests will not work as `$TMPDIR` produces a path that is
too long for unix sockets on the platform.
2016-05-31 13:27:50 -06:00
Mike Place
4eb272da3c Merge pull request #33510 from pass-by-value/salt_cloud_env_vars
Add SDB module for environment variables
2016-05-26 12:26:16 -07:00
Aditya Kulkarni
5cae7e5b1f Add SDB module for environment variables 2016-05-25 17:18:35 -04:00
Pedro Algarvio
17798f7b69
We need to use a multiprocessing Queue 2016-05-23 13:57:22 +01:00
Pedro Algarvio
3adf8e286e
Some more test suite run fixes
* Allow more time for the daemons to react to the signals sent
* Fix configuration
* More logging
2016-05-23 13:57:21 +01:00
twangboy
b60bc974a0
Fix clean function for windows 2016-05-23 13:56:06 +01:00
Pedro Algarvio
73165d8701
Break on broken pipe 2016-05-23 13:56:05 +01:00
Pedro Algarvio
a17aefd04a
Handle connection errors 2016-05-23 13:56:05 +01:00
Pedro Algarvio
e0b177a493
We need to import logging within the threaded call 2016-05-23 13:56:04 +01:00
Pedro Algarvio
cdfd5224c8
log was out of scope, better use the module 2016-05-23 13:56:04 +01:00
Pedro Algarvio
e1e1aeb3d7
Keep ports open throughout the tests execution 2016-05-23 13:56:02 +01:00
Pedro Algarvio
7a8460856c
Define IDs and ports on sample configs 2016-05-23 13:56:01 +01:00
Pedro Algarvio
184c3c83ad
Run the test daemons from CLI
This should help running the test suite on Windows machines
2016-05-23 13:56:00 +01:00
rallytime
7bf9f5d0f5 Merge branch '2016.3' into 'develop'
Conflicts:
  - doc/man/salt.7
  - doc/ref/executors/all/salt.executors.direct_call.rst
  - doc/ref/executors/all/salt.executors.splay.rst
  - doc/ref/executors/all/salt.executors.sudo.rst
  - salt/cloud/clouds/vultrpy.py
2016-05-18 09:40:48 -06:00
C. R. Oldham
8387657d9a Prevent salt-cloud from hanging when spinning up new Vultr instances (#33272)
* better support for named images, locations, sizes

* better support for named images, locations, sizes

* Tests for Vultr driver

* Add sleep so test instance will be old enough to delete as part of the test

* Lint.
2016-05-16 13:11:29 -07:00
rallytime
ced033c0a4 Merge branch '2016.3' into 'develop'
Conflicts:
  - doc/topics/releases/2016.3.0.rst
  - salt/scripts.py
  - salt/states/glusterfs.py
2016-05-06 16:05:58 -06:00
rallytime
180c03ca24 Merge branch '2015.8' into '2016.3'
Conflicts:
  - salt/cli/salt.py
  - salt/modules/zypper.py
  - salt/scripts.py
  - salt/states/boto_elb.py
  - tests/integration/states/user.py
  - tests/unit/states/file_test.py
2016-05-06 09:20:05 -06:00
Nicole Thomas
111701c8bb [2015.8] Merge forward from 2015.5 to 2015.8 (#33054)
* Add run_on_start docs to schedule.rst (#32958)

Fixes #22580

* Backport #33021 manually to 2015.5 (#33044)

* Saltfile with pillar tests (#33045)

* add file.managed with pillar data tests

* do not require git for other tests

* Whitespace...
2016-05-05 07:05:55 -07:00
rallytime
16c9ce70ad Merge branch '2016.3' into 'develop'
No conflicts.
2016-05-02 12:58:24 -06:00
Justin Findlay
cc854f1464 update pip state and integration tests for newer pip versions (#32905)
* modules.virtualenv_mod: use correct pip bootstrap url

* modules.pip: raise error on mirrors arg

* states.pip: run mirrors test on < 7.0.0

* update pip integration test states to not use mirrors

* modules.pip: run mirrors tests on pip < 7.0.0
2016-04-29 10:49:29 -07:00
Nicole Thomas
216d9fdc9a [develop] Merge forward from 2016.3 to develop (#32494)
* fix sorting by latest version when called with an attribute

* remove reference to master_alive_check

* Fixes saltstack/salt#28262

* Resolve memory leak in authentication

* outputter virt_list does not exist anymore

* Update proxmox documentation

* Fix documentation on boto_asg and boto_elb modules and states

* modules.win_timezone: don't list all zones in debug log

* Correcty index glusterfs bricks

Fixes issue #32311

* Cleaner deprecation process with decorators

* Add deprecation decorator scaffold

* Capture type error and unhandled exceptions while function calls

* Aware of the current and future version of deprecation

* Implement initially is_deprecated decorator

* Add an alias for the capitalization

* Fix capitalization easier way

* Remove an extra line

* Add successor name to the deprecation decorator.

* Granulate logging and error messages.

* Implement function swapper

* Raise later the caught exception

* Clarify exception message

* Save function original name

* Remove an extra line

* Hide an alternative hidden function name in the error message, preserving the error itself

* Rename variable as private

* Add a method to detect if a function is using its previous version

* Message to the log and/or raise an exception accordingly to the status of used function

* Log an error along with the exception

* Add internal method documentation

* Add documentation and usage process for decorator "is_deprecated"

* Add documentation and process usage for the decorator "with_deprecated"

* Hide private method name

* Fix PEP8, re-word the error message

* Deprecate basic uptime function

* Add initial decorator unit test

* Rename old/new functions, mock versions

* Move frequent data to the test setup

* Add logging on EOL exception

* Rename and document high to low version test on is_deprecated

* Implement a test on low to high version of is_deprecated decorator

* Add a correction to the test description

* Remove a dead code

* Implement a test for high to low version on is_deprecated, using with_successor param

* Correct typso adn mistaeks

* Implement high to low version with successor param on is_deprecated

* Setup a virtual name for the module

* Implement test for with_deprecated should raise an exception if same deprecated function not found

* Implement test for with_deprecated an old function is picked up if configured

* Correct test description purpose

* Implement test with_deprecated when no deprecation is requested

* Add logging test to the configured deprecation request

* Add logging testing when deprecated version wasn't requested

* Implement test EOL for with_deprecated decorator

* Correct test explanation

* Rename the test

* Implement with_deprecated no EOL, deprecated other function name

* Implement with_deprecated, deprecated other function name, EOL reached

* Add test description for the with_deprecated + with_name + EOL

* Fix confusing test names

* Add logging test to the is_deprecated decorator when function as not found.

* Add more test point to each test, remove empty lines

* Bugfix: at certain conditions a wrong alias name is reported to the log

* Fix a typo in a comment

* Add test for the logging

* Disable a pylint: None will _never_ be raised

* Fix test for the deprecated "status.uptime" version

* Bugfix: Do not yank raised exceptions

* Remove unnecessary decorator

* Add test for the new uptime

* Add test for the new uptime fails when /proc/uptime does not exists

* Rename old test case

* Skip test for the UTC time, unless freeze time is used.

* Fix pylint

* Fix documentation

* Bugfix: proxy-pass the docstring of the decorated function

* Lint fix

* Fixes saltstack/salt#28262 for 2015.5 branch

* Update master config docs

* Improve git_pillar documentation/logging

* Add note about different behavior of top file in git_pillar

* Make log entry for a missing pillar SLS file more accurate for git_pillar

* FreeBSD supports packages in format java/openjdk7 so the prior commit broke that functionality. Check freebsd/pkg#1409 for more info.

* FreeBSD supports packages in format java/openjdk7 so the prior commit broke that functionality. Check freebsd/pkg#1409 for more info.

* Update glusterfs_test to be inline with #32312

* Fix salt-cloud paralell provisioning

Closes #31632

* Ignore Raspbian in service.py __virtual__ (#32421)

* Ignore Raspbian in service.py __virtual__

This prevents more than one execution module from trying to load as the
service virtual module.

Refs: #32413

* pack __salt__ before loading provider overrides

We can (and should) pack here since we're just packing a reference to the
object. __salt__ needs to be available when we're loading our provider
overrides

* Fix broken __salt__ dict in provider override

Using ret.items() here sets ``__salt__`` to its items (tuple containing
function name and reference), breaking usage of ``__salt__`` inside
overridden functions.

* Merge #32293 with test fixes (#32418)

* Fix issue #11497

* Remove check for working directory presence in tests

* Fix Domainname introspection

Default value needs to be extracted from the container itself,
because dockerd set Domainname value when network_mode=host.

* Add pgjsonb_queue to queue doc index

* Pylint fixes

* Pass parser options into batch mode

Resolves #31738

* Changed the target file in file.symlink test (#32443)

* Argument name in docs should match actual arg name (#32445)

Fixes #31851

* tests.integration: bypass MacOS TMPDIR, gettempdir (#32447)

Updates 0edd532, 8f558a5.

When logging in as root over `ssh root@host`, `$TMPDIR` and
`tempfile.gettempdir()` are both set to a variation of:
```
/private/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/
```
When logging in as root over `sudo -i`, `$TMPDIR` is unset and
`tempfile.gettempdir()` is set to `/tmp`.

My guess is that the second case is an unintended or uncorrected omision
by Apple as they have introduced the longer, randomized temp path in a
recent version of MacOS.

* Issue #28706: Fix state user.present behavior. (#32448)

- As mentionned in issue #28706, state user.present no longer remove
      user from groups if the keyword 'groups' with empty value '[]' is not
      explicitly set, salt will assume current groups are still wanted.

* tests.integration: fix 4230c8a

* Move the tables of virtual modules to individual documentation pages

* Add new doc pages to toctree

* Add external ref to windows package manager docs

* Improve docstrings

* Add documentation on virtual module provider overrides to the module docs

* Clarify the scope of the provider param in states.

* Add link to provider override docs to all package providers

* Add link to provider override docs to all service providers

* Add link to provider override docs to all user providers

* dd link to provider override docs to all shadow providers

* Add link to provider override docs to all group providers

* Backport 31164 and 31364 (#32474)

* Don't send REQ while another one is waiting for response.

The message has to be removed from the queue the only *after* it's
already processed to don't confuse send() functionality that expects
empty queue means: there's no active sendings.

* Fixed zeromq ReqMessageClient destroy

* Add link to provider override docs to opkg.py

This is a companion to https://github.com/saltstack/salt/pull/32458, but
this module was not added until the 2016.3 branch, so the documentation
is being updated there for this module.

* Add documentation for some master/minion configs (#32454)

Refs #32400

Adds docs for:

- cli_summary
- event_return_queue
- event_return_whitelist
- event_return_blacklist
- file_recv_max_size
- fileserver_followsymlinks
- fileserver_ignoresymlinks
- fileserver_limit_traversal

* Automatically detect correct MySQL password column for 5.7 and fix setting passwords (#32440)

* Automatically detect MySQL password column

* Fix changing password in MySQL 5.7

* Fix lint test

* Fix unit tests (?)

They will still fail if "authentication_string" is legitimately the right column name, but I don't know what to do about that.

* Additional unit test fix

* Only unsub if we have a jid

Closes #32479
2016-04-11 17:07:15 -06:00
Justin Findlay
117d641830 tests.integration: fix 4230c8a 2016-04-08 16:54:00 -06:00
Justin Findlay
fa8d030ab7 tests.integration: bypass MacOS TMPDIR, gettempdir (#32447)
Updates 0edd532, 8f558a5.

When logging in as root over `ssh root@host`, `$TMPDIR` and
`tempfile.gettempdir()` are both set to a variation of:
```
/private/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/
```
When logging in as root over `sudo -i`, `$TMPDIR` is unset and
`tempfile.gettempdir()` is set to `/tmp`.

My guess is that the second case is an unintended or uncorrected omision
by Apple as they have introduced the longer, randomized temp path in a
recent version of MacOS.
2016-04-08 16:00:48 -06:00
rallytime
eb6773823b Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/modules/rh_service.py
2016-04-01 10:33:44 -06:00
Justin Findlay
8f558a5f41 tests...runtests_helpers: TMPDIR on MacOS gives too long paths 2016-03-30 21:09:40 -06:00
Justin Findlay
c74c241831 tests.integration: use os.path.realpath
This reverts bf894c37, 6b99798b, and 4028d80e.  `os.path.realpath`
behaves identically to `salt.utils.abs_readlink` on the doc tests in
that function.
2016-03-30 21:09:39 -06:00
rallytime
d684d49490 Merge branch '2016.3' into 'develop'
Conflicts:
  - doc/topics/releases/2015.5.10.rst
  - doc/topics/releases/2015.8.8.rst
2016-03-28 11:16:22 -06:00
Ch3LL
b8f271bdc9 add mac_keychain test 2016-03-26 20:30:22 -06:00
rallytime
308aa5fd61 Merge branch '2016.3' into 'develop'
Conflicts:
  - conf/master
  - conf/minion
  - doc/ref/proxy/all/index.rst
  - salt/cli/daemons.py
  - salt/modules/key.py
  - salt/modules/reg.py
  - salt/modules/win_pkg.py
  - salt/utils/__init__.py
  - salt/utils/cloud.py
  - tests/unit/daemons_test.py
2016-03-18 10:57:15 -06:00
Justin Findlay
4028d80eee tests...runtests_helpers: use system tmpdir 2016-03-10 10:57:18 -07:00
rallytime
2ee175c6d3 Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/fileclient.py
  - salt/modules/glusterfs.py
2016-03-02 13:48:11 -07:00
rallytime
031a75ca33 Merge branch '2015.8' into '2016.3'
Conflicts:
  - Contributing.rst
  - conf/master
  - doc/index.rst
  - doc/man/salt.7
  - pkg/suse/README.suse
  - salt/client/ssh/state.py
  - salt/minion.py
  - salt/modules/zypper.py
  - salt/utils/schedule.py
  - tests/unit/modules/zypper_test.py
2016-03-02 10:26:13 -07:00
Denys Havrysh
86433f2378 Revert changes in files used by roots_test.py integration test 2016-03-02 10:00:45 +02:00
Denys Havrysh
e7a8dbf498 Remove trailing white spaces in tests files 2016-03-01 17:40:02 +02:00
rallytime
40cd0ac8fe Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/states/file.py
  - tests/runtests.py
2016-02-25 16:21:15 -07:00
Nicole Thomas
625da0d261 Merge pull request #31471 from cachedout/issue_31427
Correct issue where duplicate items in grains list during state run will result in duplicate grains
2016-02-25 13:15:20 -07:00
rallytime
3b74d123af Merge branch '2015.8' into '2016.3'
Conflicts:
  - salt/modules/selinux.py
  - salt/modules/zypper.py
  - salt/pillar/__init__.py
  - salt/states/dockerng.py
  - tests/runtests.py
2016-02-25 12:36:22 -07:00
Mike Place
30eb5fccf7 Additional tests, but disable the test for distinct lists, because of a problem with context in test suite 2016-02-24 13:53:49 -07:00
justinta89
421a112914 Added config_dir to test minion config 2016-02-23 19:40:22 -07:00
Mike Place
e1ade05e54 Merge pull request #31355 from rallytime/fix-31330
Fix orchestrate outputter when retcode is appended to orchestrate run
2016-02-22 11:13:07 -07:00
rallytime
38f89bf8fd Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/beacons/inotify.py
  - salt/beacons/load.py
2016-02-21 15:23:24 -07:00
Justin Findlay
8623c24335 add integration tests for minion blackout
Related to #30868.
2016-02-19 18:04:31 -07:00
rallytime
9b52e39e90 Add testcase for state.orchestrate output 2016-02-19 09:14:46 -07:00
rallytime
cc29092dcb Merge branch '2016.3' into 'develop' 2016-02-18 11:33:24 -07:00
rallytime
7ea9dacbdd Merge branch '2015.8' into '2016.3'
Conflicts:
  - salt/beacons/inotify.py
  - salt/beacons/load.py
  - salt/minion.py
  - salt/modules/win_update.py
  - salt/modules/yumpkg.py
  - salt/utils/pkg/rpm.py
2016-02-18 11:10:44 -07:00
Mike Place
9281ff5b1f Merge pull request #31307 from LoveIsGrief/salt-27089-new
[Recreated]Saltcloud virtualbox provider
2016-02-18 08:56:21 -07:00
Ch3LL
da9bca625e pkg.latest epoch test for 2016 2016-02-17 09:51:11 -07:00
Mike Place
c5e5af827c Merge pull request #31171 from Ch3LL/megan-20158
added logic to check for installed package
2016-02-12 15:10:21 -07:00
Ch3LL
9204e3f562 add integration test for issue 30934w 2016-02-12 12:21:50 -07:00
Ch3LL
a123efd4ef added logic to check for installed package 2016-02-12 11:01:35 -07:00
Colton Myers
076b49a4ca Merge remote-tracking branch 'upstream/2015.8' into merge-forward-2016.3
Conflicts:
    README.rst
    doc/conf.py
    doc/ref/index.rst
    doc/ref/proxy/all/salt.proxy.ssh_sample.rst
    doc/topics/installation/rhel.rst
    doc/topics/releases/2015.8.4.rst
    doc/topics/tutorials/states_pt5.rst
    salt/cloud/clouds/ec2.py
    salt/cloud/clouds/opennebula.py
    salt/config/__init__.py
    salt/modules/boto_dynamodb.py
    salt/modules/boto_ec2.py
    salt/modules/boto_elasticache.py
    salt/modules/boto_elb.py
    salt/modules/boto_iam.py
    salt/modules/boto_rds.py
    salt/modules/boto_sns.py
    salt/modules/boto_sqs.py
    salt/modules/dracr.py
    salt/modules/git.py
    salt/modules/mine.py
    salt/modules/systemd.py
    salt/modules/win_pkg.py
    salt/modules/yumpkg.py
    salt/pillar/__init__.py
    salt/states/git.py
    salt/states/rabbitmq_vhost.py
    salt/states/saltmod.py
    salt/utils/pkg/rpm.py
    setup.py
    tests/unit/modules/systemd_test.py
    tests/unit/states/rabbitmq_vhost_test.py
2016-02-11 22:33:49 -07:00
Ch3LL
af82b1233a integration test for issue #31014 2016-02-10 21:46:22 -07:00