Commit Graph

941 Commits

Author SHA1 Message Date
Justin Anderson
ebee8a89af glance.warn_until shouldn't be checked for a doc string 2016-06-02 16:30:36 -06:00
Justin Anderson
86f59b3e80 Made more pythonic 2016-06-02 14:37:05 -06:00
Justin Anderson
2f36f34981 Fixed salt.util import. Added status check to make sure external resource is available 2016-06-02 14:32:08 -06:00
Justin Anderson
400a71ec33 Removed redundancies 2016-06-02 11:16:23 -06:00
Justin Anderson
91db411bea A couple lint fixes 2016-06-02 09:03:10 -06:00
Justin Anderson
c97f3319b9 Add check for gem binary 2016-06-02 08:56:09 -06: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
rallytime
b7accb0b3b Merge branch '2015.8' into '2016.3'
Conflicts:
  - salt/utils/aws.py
  - salt/utils/s3.py
2016-06-02 10:01:43 -04:00
Justin Anderson
210aceb402 Refactored tests to not use return messages 2016-06-01 16:57:37 -06:00
Mike Place
c8dc70b96a Merge pull request #33685 from jfindlay/get_url_test
modules.cp.get_url: add test for https://
2016-06-01 15:25:41 -07:00
Justin Anderson
9d437bd45d Removed artifact from testing 2016-06-01 15:32:41 -06:00
Justin Anderson
134e1fa888 Fixed typos, and added destructiveTest decorator 2016-06-01 15:25:18 -06:00
Justin Anderson
37bc3ad8fd Fixed typo, uninstalled to uninstall 2016-06-01 15:16:15 -06:00
Justin Findlay
2b5035fdc0 modules.cp.get_url: add test for https:// 2016-06-01 15:10:12 -06:00
Justin Anderson
5b23b91ac6 Integration test for gem module 2016-06-01 15:09:55 -06:00
Drew Adams
bcd6a1cd77 fix osfamily from Suse to SUSE 2016-05-26 22:08:40 -07:00
Justin Findlay
0ed3598fc9 modules.mac_brew int tests: add latest_version test 2016-05-25 22:15:12 -06:00
Justin Findlay
8789c2d06d modules.mac_brew int tests: add list_upgrades,info_installed 2016-05-25 22:05:01 -06:00
Justin Findlay
be381e0fc9 modules.mac_brew int tests: move decorators to class
Also remove unneeded system grains code.
2016-05-25 22:05:01 -06:00
rallytime
af8c6b7894 Allow exact arg matches to work in sys.list_modules func
Fixes #33500
2016-05-25 14:26:59 -06:00
rallytime
a5e0141eda Merge branch '2015.8' into '2106.3'
Conflicts:
  - salt/beacons/__init__.py
  - salt/modules/saltutil.py
  - salt/modules/zypper.py
  - salt/states/grains.py
  - salt/states/pkgrepo.py
  - salt/states/service.py
2016-05-25 13:44:21 -06:00
Justin Anderson
ebf1256545 Don't need to check swift.head due to it having no body 2016-05-24 15:26:28 -06:00
Justin Anderson
59e90064e6 modules.swift.head does not have a body. Should not be checked for a docstring right now. 2016-05-24 14:58:32 -06:00
Nicole Thomas
0c4e38ced4 Fix the saltutil.wheel function and add integration tests (#33414)
* Fix the saltutil.wheel function and add integration tests

Fixes #32446

* Provide a more useful message when command is run on non-local minion
2016-05-23 14:11:16 -07:00
Jεan Sacren
8685ffa2e9 Add timezone integration test for Solaris (#33167) 2016-05-12 14:40:37 -07:00
Nicole Thomas
457d9dd4f5 [develop] Merge forward from 2016.3 to develop (#33193)
* 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

* Fix minor document error of test.assertion (#33067)

* test pillar.items output (#33060)

* File and User test fixes for 2015.5 on Fedora23 (#33055)

* Fix file_test.test_symlink on 2015.5

* Fix failing user present test

* add test for installing package while using salt-call --local (#33025)

* add test for installing package while using salt-call --local

* fix pylint

* ssh docs: install py-2.6 for RHEL 5

* Bugfix: Restore boolean values from the repo configuration

* Add test data for repos

* Add repo config test

* Bugfix (follow-up): setting priority requires non-positive integer

* modules.npm: do not log npm --version at info level (#33084)

* salt-cloud: fix ipv6-only virtual machines (#32865)

* salt-cloud: fix ipv6-only virtual machines

* fix hostname for rsync fallback in scp_file function

* use 4 spaces instead of 2

* remove global variable, use direct socket call instead

* Use saltstack repo in buildpackage.py on CentOS 5 (#33080)

* Lower display of msgpack failure msg to debug (#33078)

Closes #33074

* cloud.query needs to define mapper.opts (#33098)

* clarify docs that map is designed to be run once. is not stateful (#33102)

* Moved _finger_fail method to parent class.

Method _finger_fail method from SAuth to AsyncAuth class to make method available
in both class and fix an issue where _finger_Fail is called inside AsyncAuth.

* Fix 33058 (#33099)

* Fix servermanager module

- Added check for 2008 version of windows
- Added Import-Module ServerManager to _pshell_json.
  Apparently this needs to run each time we issue a
  servermanager command.

* Fix list_available

* salt.utils.gitfs: fix formatting for warning messages (#33064)

* salt.utils.gitfs: fix formatting for warning messages

When git_pillar support was added to salt.utils.gitfs, the
recommendation globals had string formatting placeholders added to them,
but the locations where these values are referenced do not call
``.format()`` to properly replace them. This commit fixes that
oversight.

* Remove more gitfs and master-specific wording from log messages

* Add a check that the cmdline of the found proc matches (#33129)

* Doc mock decorators (#33132)

* Add mock function for mocking decorators

* Mock the stdlib user module because importing it will open the repl

* Fix broken parsing of usermgmt.conf on OpenBSD (#33135)

When creating a new user, if a group of the same name already exists,
the usermgmt.conf file is consulted to determine the primary group.
It's in these cases that the parsing bug is triggered.

This code change addresses several of the existing issues:

- The previous split statement explicitly specified a single space.
  Since a config line may have any number of spaces and/or tabs
  surrounding the entries, the resulting array's elements may be
  incorrect.

- According to the man pages for usermgmt.conf, the "group" config
  entry accpets a single parameter -- so we shouldn't iterate.

- The "val[1]" was returning the 2nd letter of each word and not the
  second word on the config line as intended.

* Move salt-ssh thin dir location to /var/tmp (#33130)

* Move salt-ssh thin dir location to /var/tmp

Closes #32771

* Remove performance penelty language

* If cache_jobs: True is set, populate the local job cache when running salt-call (#33100)

* If cache_jobs: True is set, populate the local job cache

Fixes #32834

Allows a masterless minion to query the job cache.

* Refactor cache_jobs functionality to be DRY

* Skipping salt-call --local test

* Back-port #31769 to 2015.8 (#33139)

* Handle empty acl_name in linux_acl state

Calls to setfacl interpret an empty group or user name to mean to be the
owner of the file they're operating on. For example, for a directory
owned by group 'admin', the ACL 'default:group::rwx' is equivalent to
'default:group:admin:rwx'.

The output of the getfacl execution module returns ACLs in the format of
'group:admin:rwx' instead of 'group::rwx'. This commit changes the
acl.present state to look for the owner of the file if the acl_name
paremeter is empty.

* Fix acl.present/acl.absent changing default ACLs

The behaviour of the acl.present and acl.absent is to check the data
structure returned by getfacl contains a key by the name of acl_type.

However, this data structure does not contain any default ACLs if none
exist, so this check will fail. We omit the check if a default ACL was
passed into the state functions.

Unfortunately, the call to modfacl may fail if the user passes in an
acl_type such as 'default:random'. In this case the state will appear to
succeed, but do nothing.

This fixes the state module to allow setting default ACLs on files which
have none.

* Fix regression in 2016.3 HEAD when version is specified (#33146)

Resolves #33013.

* Hash fileclients by opts (#33142)

* Hash fileclients by opts

There was an issue whereby the cache of the fileclient was being overwritten
by dueling minion instances in multimaster mode. This protects them by hashing
by the id of opts.

Closes #25040

* Silly typo!

* Remove tests which do not test any actual functionality or are too tightly coupled to the implementation

* Strip ldap fqdn (#33127)

* Add option to strip off domain names on computer names that come from LDAP/AD

* Add strip_domains option for ldap.

* Add documentation for auth.ldap.minion_stripdomains.

* [2015.5] Update to latest bootstrap script v2016.05.10 (#33155)

* [2015.8] Update to latest bootstrap script v2016.05.10 (#33156)

* [2016.3] Update to latest bootstrap script v2016.05.10 (#33157)

* add 2015.5.11 release notes (#33160)

* add 2015.8.9 release notes (#33161)

* Pip fix (#33180)

* fix pip!!

* make it work with old pip as well

* Added resiliency

* Don't need to check, just get the right name

* [2015.5] Update to latest bootstrap script v2016.05.11 (#33185)
2016-05-12 07:53:39 -07:00
rallytime
92e0c17645 Merge branch '2015.8' into '2016.3'
No conflicts.
2016-05-09 13:55:06 -06:00
Nicole Thomas
b6cf601722 Merge pull request #33103 from rallytime/merge-develop
[develop] Merge forward from 2016.3 to develop
2016-05-09 13:24:25 -06:00
Jεan Sacren
479e643b62 Develop 2016 0509 0030 (#33111)
* Disallow negative value for fib number

Fibonacci number is supposed to be nonnegative. Add this new feature to
disallow negative value to be passed in for fib number.

* Minimize code duplication

* Use /etc/adjtime for Gentoo

* Add integration test for timezone module
2016-05-09 10:06:44 -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
0fd5e9d157 Merge branch '2015.5' into '2015.8'
Conflits:
  - salt/minion.py
  - tests/integration/states/file.py
2016-05-06 12:04:06 -06:00
Megan Wilhite
d48b2b8b52 test pillar.items output (#33060) 2016-05-05 06:51:27 -07:00
Justin Findlay
a78bbd0544 Update mac_assistive module for El Capitan (10.11) (#33047)
* modules.mac_assistive int tests: wrap args in list

* modules.mac_assistive.install: match schema on El Capitan

* modules.mac_assistive: remove redundant LooseVersion

* modules.mac_assistive unit tests: mock __grains__
2016-05-04 15:34:03 -06:00
Jεan Sacren
ad3b8b5b3d Add integration test for gentoolkit module (#32977) 2016-05-02 08:27:09 -07:00
rallytime
cbf42a8407 Merge branch '2016.3' into 'develop'
Conflicts:
  - conf/master
  - doc/ref/configuration/master.rst
  - salt/cli/batch.py
  - salt/cli/daemons.py
  - salt/config/__init__.py
  - salt/minion.py
  - salt/modules/aptpkg.py
  - salt/modules/beacons.py
  - salt/states/archive.py
  - salt/states/cmd.py
  - salt/utils/gitfs.py
  - tests/unit/states/cmd_test.py
2016-04-26 14:42:26 -06:00
rallytime
80fcdfb9d8 Merge branch '2015.8' into '2016.3'
Conflicts:
  - doc/topics/targeting/grains.rst
  - salt/cli/daemons.py
  - salt/exceptions.py
  - salt/minion.py
  - salt/modules/schedule.py
  - salt/scripts.py
  - salt/states/archive.py
2016-04-26 12:07:42 -06:00
rallytime
9064d3bbfb Merge branch '2015.5' into '2015.8'
Conflicts:
  - salt/cloud/clouds/vmware.py
  - salt/modules/file.py
  - salt/states/archive.py
2016-04-25 15:45:17 -06:00
Erik Johnson
67d0c81184 Support remote sources in a source list (#32691)
* Support remote sources in a source list

This commit modifies the source_list check so that remote sources
(http(s), ftp, etc.) are not fetched more than once. To do so, it
adds the use of ``__context__`` in ``cp.cache_file`` and
``file.source_list`` to prevent multiple fetches of a single file in the
same salt run.

* Update tests

Added __context__ to test cases to reflect usage of __context__, and
also added file.source_list to mocked funcs for archive.extracted unit
test.
2016-04-21 08:37:38 -06:00
Nicole Thomas
9942ea9319 [develop] Merge forward from 2016.3 to develop (#32636)
* Ensure rh_service not used on CloudLinux 7

Add CloudLinux to RHEL-derived distros excluded from rh_service use in osrelease >= 7

* Fix binary search and replace (#32542)

* Don't return None from eval_master (#32555)

Raise an exception instead. Because eval master if returns should return
a tuple.

* redact passwords and hashes from user.present updates

Fixes #32381

* Better log message on minion restart if master couldn't be reached. (#32576)

* Revert PR #32480 and apply #32314 with fixes / documentation (#32558)

* Revert "Fix loop in maint.flo"

This reverts commit 5196cd6a6e5db3c7b1a47b1740881bbd3e87ea3d.

* Revert "Clear VCS fsbackend and git_pillar locks on master start"

This reverts commit 7e3caa9bae1ac4de62db9924374e35a8b826937e.

* Revert "Add functions to remove VCS fsbackend update locks and git_pillar update/checkout locks"

This reverts commit 4c2db32419022501eae2a695ec488693e043d189.

* prevent eternal gitfs lock due to process crash

* Use salt.utils.fopen() instead of open()

* Make pid locking work for more than just gitfs

Also, make logging more descriptive, to aid in troubleshooting.

* Add git_pillar_global_lock config option default value

* Document proper usage of {gitfs,git_pillar}_global_lock

* Fix comments value in salt.states.pkgrepo example (#32604)

'comments' option adds '#' automatically. Example contains `#http://mirror.centos.org/centos/$releasever/os/$basearch/` string which becomes prefixed with '##' in generated file.

* alphabetize directories for dynamic modules (#32599)

Also add engines and proxy minions to the list.

* Expand on the open-source vs open-core FAQ

* Language clarification.

* Fix some mistakes in the salt-ssh thin shell script (#32583)

* [[ is bash, not compatible with /bin/sh

* check if python command exists before calling it

* Deprecate 'user' and 'group' in state cmd (#32613)

* Remove unused 'group' argument

* Fix unit testing of cmd.mod_run_check without group arg

* Deprecate 'user/group' in cmd.run

* Deprecate 'user'/'group' in cmd.script

* Deprecate 'user' in cmd.wait

* Deprecate 'user'/'group' in cmd.wait_script

* Fix mod_run_check without 'group'

* Push deprecation back one release

* Fix mac_service and mac_system modules (#32587)

* Fix mac_service module

* Add integration tests for new functions

* Start will not enable the service beforehand

* Remove unused variables
2016-04-18 08:40:20 -06:00
Shane Lee
97111bdc9b Fix mac_service and mac_system modules (#32587)
* Fix mac_service module

* Add integration tests for new functions

* Start will not enable the service beforehand

* Remove unused variables
2016-04-15 15:49:44 -06:00
rallytime
eb6773823b Merge branch '2016.3' into 'develop'
Conflicts:
  - salt/modules/rh_service.py
2016-04-01 10:33:44 -06:00
rallytime
fa5e17b342 Merge branch '2015.8' into '2016.3'
Conflicts:
  - salt/modules/win_service.py
  - salt/modules/zypper.py
  - salt/states/pkgrepo.py
2016-03-30 15:33:13 -06:00
rallytime
d743f8cc4e Merge branch '2015.5' into '2015.8'
Conflicts:
  - salt/client/ssh/__init__.py
  - salt/modules/aptpkg.py
  - salt/modules/zypper.py
  - salt/states/pkgrepo.py
2016-03-30 13:38:38 -06:00
Mike Place
4a5d1b1dd3 Merge pull request #31768 from twangboy/mac_xattr_int
Integration Tests for mac_xattr.py
2016-03-30 13:03:25 -06:00
Mike Place
2816982178 Merge pull request #31959 from twangboy/mac_timezone_int
Integration tests for mac_timezone.py
2016-03-30 13:03:15 -06:00
twangboy
dfe148934b Fix typo 2016-03-30 12:56:39 -06:00
twangboy
a45d2270df Remove test for _convert_to_datetime 2016-03-30 12:56:39 -06:00
twangboy
845809139c Add test for _convert_to_datetime 2016-03-30 12:56:39 -06:00
twangboy
3a6ad91509 Fix some pylint errors 2016-03-30 12:56:39 -06:00
twangboy
f1a5134b92 Total rewrite of mac_shadow.py
Updated mac_shadow integration tests
2016-03-30 12:56:39 -06:00
twangboy
c62920fb08 Add destructiveTest decorators 2016-03-30 12:56:39 -06:00
twangboy
9fe91a8fb5 Fix __random_string assignment 2016-03-30 12:56:39 -06:00
twangboy
1da27172b9 Add integration tests for mac_shadow 2016-03-30 12:56:39 -06:00
Erik Johnson
5c1bdb812c Fix pkgrepo integration test
Also re-enabled test on ubuntu 15.10.
2016-03-30 11:34:55 -05:00
twangboy
cedc14e6f5 Fix tests for read and delete 2016-03-30 08:56:49 -06:00
twangboy
cbd868e12a Improve integration tests 2016-03-30 08:56:49 -06:00
twangboy
1934a17f8e Add additional error handling 2016-03-30 08:56:49 -06:00
twangboy
833d63c27d Raise errors on command failures 2016-03-30 08:56:49 -06:00
twangboy
6f98a5204f Fix xattr.list returning None
Fixes tests
Removes super calls from setUp and tearDown
2016-03-30 08:56:49 -06:00
twangboy
bacaa9c4c0 Add missing import 2016-03-30 08:56:49 -06:00
twangboy
1094754085 Gate the tests for Mac OS X 2016-03-30 08:56:49 -06:00
twangboy
ab205f52d4 Fix some lint errors 2016-03-30 08:56:49 -06:00
twangboy
cd4c84a7eb Fix problem with xattr.list tests 2016-03-30 08:56:49 -06:00
twangboy
f54139fb9f Fix some tests 2016-03-30 08:56:49 -06:00
twangboy
fd96733fc7 Put test file in correct state for each test 2016-03-30 08:56:49 -06:00
twangboy
212590b130 Add remaining test functions 2016-03-30 08:56:49 -06:00
twangboy
8b8d35ef8b Add if main statement 2016-03-30 08:56:49 -06:00
twangboy
677c4384b0 Add integration test file for mac_xattr 2016-03-30 08:56:49 -06:00
twangboy
fedc5c367c Use class attributes instead of global variables 2016-03-30 08:46:02 -06:00
twangboy
54059b33a0 Add global variables for setUp function 2016-03-30 08:46:02 -06:00
twangboy
fb82553be7 Add instructions for parallels time sync
Re-added tests that were having problems caused
by parallels time sync
2016-03-30 08:46:02 -06:00
twangboy
19ec1ea837 Fix some tests 2016-03-30 08:46:02 -06:00
twangboy
4e89f8f124 Fix tests 2016-03-30 08:46:02 -06:00
twangboy
1050dbe6ec Simplified tests 2016-03-30 08:46:02 -06:00
twangboy
abfd8fbd85 Fix test_get_zonecode 2016-03-30 08:46:02 -06:00
twangboy
0ea5a6e91c Fix test_get_time 2016-03-30 08:46:02 -06:00
twangboy
155694e4c1 Remove possible race conditions 2016-03-30 08:46:02 -06:00
twangboy
8fa35de6e5 Add destructiveTest decorators 2016-03-30 08:46:02 -06:00
twangboy
52007746a6 Fix get_set_time test 2016-03-30 08:46:02 -06:00
twangboy
213c400c03 Fix timezone test 2016-03-30 08:46:02 -06:00
twangboy
3c31bea8c1 Add integration test enhancements 2016-03-30 08:46:02 -06:00
twangboy
2583af0d94 Added SaltInvocationError exceptions 2016-03-30 08:46:02 -06:00
twangboy
d3f1685bc0 Add remaining tests 2016-03-30 08:46:02 -06:00
twangboy
ed5b9cf68b Fix systemsetup gate 2016-03-30 08:46:02 -06:00
twangboy
b14b36307a Add tests for mac_timezone 2016-03-30 08:46:02 -06:00
rallytime
40d09c822e Add some "best practices" information to test documentation
Also clarifies some sections and fixes some broken links.
2016-03-28 14:23:42 -06:00
rallytime
2a27af4e1f Pylint fix 2016-03-28 11:47:57 -06:00
rallytime
8531847e3f Pylint fix 2016-03-28 11:42:54 -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
rallytime
635263ab1c Finish up mac_keychain tests 2016-03-26 20:30:22 -06:00
Ch3LL
b8f271bdc9 add mac_keychain test 2016-03-26 20:30:22 -06:00
twangboy
86de04b08c Fix typo in test_latest_version 2016-03-25 15:28:46 -06:00
twangboy
9c97057b84 Add destructiveTest decorators 2016-03-25 15:28:46 -06:00
twangboy
770b45ca35 Fix class attribute 2016-03-25 15:28:46 -06:00
twangboy
ada508f8eb Improve cleanup 2016-03-25 15:28:46 -06:00
twangboy
b63986d2ce Add remaining integration tests 2016-03-25 15:28:46 -06:00
Nicole Thomas
abace3aa5f Merge pull request #32151 from rallytime/merge-2016.3
[2016.3] Merge forward from 2015.8 to 2016.3
2016-03-25 14:06:15 -06:00
rallytime
f6d9cdc633 Merge branch '2015.8' into '2016.3'
Conflicts:
  - doc/ref/states/compiler_ordering.rst
  - doc/topics/installation/suse.rst
  - doc/topics/jobs/schedule.rst
  - doc/topics/targeting/grains.rst
  - doc/topics/tutorials/preseed_key.rst
  - doc/topics/tutorials/states_pt5.rst
  - pkg/suse/use-forking-daemon.patch
  - salt/minion.py
  - salt/modules/pacman.py
  - salt/modules/state.py
  - salt/modules/yumpkg.py
2016-03-25 11:47:16 -06:00
Mike Place
e24d285436 Merge pull request #32092 from twangboy/mac_service_int
Integration tests for mac_service.py
2016-03-25 10:39:42 -06:00
Nicole Thomas
37f2a98dc9 Merge pull request #32140 from rallytime/bp-32110
Back-port #32110 to 2016.3
2016-03-25 09:22:30 -06:00