Commit graph

479 commits

Author SHA1 Message Date
James Tanner
d9d36ce207 Add unit tests for vars_files 2014-04-10 13:55:03 -04:00
James Cammarata
567f3819b1 Fixing newline escapes in lineinfile
Fixes #5679
2014-04-08 11:42:29 -05:00
James Cammarata
b73cddc485 Revert "Fix #5679 again after recent changes in core"
This reverts commit 2bfaacd170.

Fixes #6821
2014-04-07 09:55:59 -05:00
James Cammarata
82b24c162e Adding delimiter fixes to action_plugin + fixing local assembling with a delimiter
Also added a new integration test for assemble using local assembly
with a delimiter.
2014-04-03 16:32:35 -05:00
Matt Martz
5770428e91 Add version_compare filter 2014-04-02 20:21:30 -05:00
Michael DeHaan
10adf9f2cc Denote unit test requirements in README.md 2014-04-02 17:29:32 -04:00
James Cammarata
684d46b170 Fixing some parsing issues in authorized_key module
Also adds an integration test for authorized_key for future validation.

Fixes #6700
2014-04-02 15:02:54 -05:00
James Tanner
efba8b4771 Merge branch 'regexreplace' of git://github.com/jacobweber/ansible into jacobweber-regexreplace 2014-03-31 13:48:13 -04:00
James Cammarata
78bdb078fe Fix for bug related to async jid polling change plus a new test 2014-03-26 15:49:15 -05:00
James Cammarata
b3cdcbff75 Adding in a test for subversion export option 2014-03-25 22:21:31 -05:00
James Tanner
f9018a6f1d Ensure handlers run when meta tasks are defined and add handler integration tests
Fixes #6678
Fixes #6670
2014-03-25 13:33:52 -04:00
Serge van Ginderachter
d3eaa1b79e InventoryDir: refactor logic
Make sure all hosts and groups are unique objects
and that those are referenced uniquely everywhere.
Also fixes test_dir_inventory unit tests which were broken after previous
patches.

	modified:   lib/ansible/inventory/dir.py
2014-03-25 12:45:00 +01:00
Michael DeHaan
c42dbf80a2 Merge pull request #6586 from sivel/probline-logic-fix
Fix logic in process_common_errors for unbalanced quotes
2014-03-19 17:45:49 -04:00
Matt Martz
2aaecc5afa Fix logic in process_common_errors for unbalanced quotes 2014-03-19 13:49:31 -05:00
James Tanner
409044155d Fixes #6579 allow for vault passwords ending with newline chars
Also add a unit test for vaulteditor to verify 1.0 passwords with newline chars.
2014-03-19 14:38:11 -04:00
James Tanner
4045b793be Addresses #6550 add integration tests for pipe lookup 2014-03-18 12:29:54 -04:00
James Laska
750d9e2d59 Update credentials.yml documentation and handling
Changes include:

 * Update Makefile to use credentials.yml when it exists
 * Add details on the use of the credentials.yml file to README.md.
 * Update credentials.template comments
2014-03-18 10:17:44 -04:00
James Tanner
db3d2e1042 Fixes #6542 rewrite test string for osx compatibility 2014-03-18 09:03:55 -04:00
James Tanner
7c5ad1fa23 Fixes #6539 Workaround py26 vs py27 difflib results 2014-03-17 22:21:30 -04:00
Michael DeHaan
9da26da335 Merge branch 'ini_vars' of git://github.com/dmage/ansible into devel 2014-03-17 17:37:57 -04:00
James Cammarata
5d8c9d3f0f Merge branch 'file_fixes_clean' of https://github.com/bcoca/ansible into bcoca-file_fixes_clean 2014-03-17 14:03:26 -05:00
James Laska
4ef2603a62 Add yum+apt integration tests for auto dependency installalation
The `apt` and `yum` modules will automatically install python dependencies.
This change updates the existing integration tests to test whether auto-install
of dependencies is functioning properly.
2014-03-17 10:42:29 -04:00
Oleg Bulatov
f6a4c20cc0 Make parsing variables for hosts and groups more consistent
This commit allows to specify arrays in [group:vars] block.

Signed-off-by: Oleg Bulatov <oleg@bulatov.me>
2014-03-16 21:47:26 +04:00
Michael DeHaan
5c05982dea Merge pull request #6448 from jirutka/fix-5679-2
Fix #5679 again after recent changes in core
2014-03-16 12:43:10 -05:00
Brian Coca
2d25577e11 Fixes and cleanup to file functions and module
- unified set attribute functions ... not sure why 2 identical functions
exist with diff names, now there are 3 while i repoint all modules to 1
- fixed issue with symlinks being created w/o existing src when force=no
- refactored conditionals, simplified where possible
- added tests for symlink to nonexistant source, with both force options
- made symlink on existing attomic (force)
2014-03-15 13:54:24 -04:00
James Cammarata
28ebf1b2c9 Merge branch 'unit-tests' of https://github.com/sivel/ansible into sivel-unit-tests 2014-03-14 13:52:53 -05:00
James Laska
aacccd441b Add integration test for apt_repository
Tests several ways to specify the repository.  For every repo added, the test
asserts that:

 * the apt-cache was updated as expected (depends on `update_cache` parameter)
 * the PPA key was installed (depends on `repo` format)
2014-03-14 13:07:12 -04:00
Matt Martz
5062f4962f Unit tests for ansible.utils 2014-03-14 10:38:33 -05:00
James Cammarata
8df29e7c8b Cleaning up some exception blocks in TestModuleUtilsBasic 2014-03-13 16:24:29 -05:00
James Cammarata
69ff355726 Adding new unit tests for module_utils/basic (run_command only now) 2014-03-13 14:56:44 -05:00
James Tanner
b0d22b76bd Add an ast.parse unit test for modules to simulate ansible-doc 2014-03-13 12:01:55 -04:00
James Laska
07dd02c25a [test_ec2*] cloud integration test updates
To support parallel cloud test execution, create and provide a random string to
cloud integration tests.  The variable 'resource_prefix' can be used in cloud
roles and during resource cleanup to safely create/destroy cloud-based
resources.

Additional changes include:

 * The roles test_ec2_key and test_ec2_group were updated to use to
 {{resource_prefix}}.

 * Additionally, the Makefile was updated to set resource_prefix to a random
 string.  The Makefile will also use 'resource_prefix' during cloud_cleanup.

 * All test_ec2* roles were updated to add 'setup_ec2' as a role dependency.
2014-03-13 11:28:02 -04:00
James Laska
9cc4be2683 Correct test integration ec2 cleanup script 2014-03-12 19:29:46 -04:00
James Laska
bc678e7d7b Add credentials.template and support custom INVENTORY
Testers may override the inventory and vars-file using the environment
variables 'INVENTORY' and 'VARS_FILE'.
2014-03-12 15:45:10 -04:00
James Laska
5c9dc33e41 Additional test_git scenarios
Includes coverage for accept_hostkey and additional scm URL formats.
2014-03-12 15:45:10 -04:00
Jakub Jirutka
2bfaacd170 Fix #5679 again after recent changes in core 2014-03-12 18:21:53 +01:00
James Laska
551cb1892b Always run cleanup after running cloud_integration tests 2014-03-12 08:37:01 -04:00
James Tanner
0d6f6ad282 Implement new default cipher class AES256 2014-03-10 16:15:44 -05:00
Dolph Mathews
8808e029f9 spelling correction for "separate"
s/seperate/separate/

http://en.wiktionary.org/wiki/separate
2014-03-08 04:51:34 -06:00
Richard C Isaacson
a483e42583 unarchive module: Add creates functionality.
Closes GH-5354.

Forklift copy logic into unarchive. Provides integration unit tests.
2014-03-07 18:19:46 -06:00
James Laska
c7d1c1a306 [test_service] correct upstart service name and permissions
The 'service' utility was unable to find the 'ansible_test' service due to an
unexpected filename.  This patch corrects the filename and adjusts the
permissions to match other service scripts within /etc/init/.
2014-03-07 10:42:13 -05:00
Richard Isaacson
119434d079 Merge pull request #6319 from risaacson/fix_test_dir_inventory
Fix TestInventory Unit Tests

Tested clean.
2014-03-06 15:43:45 -06:00
James Laska
868746b095 Correct ansible_distribution typo
Redhat != RedHat
2014-03-06 16:16:00 -05:00
James Laska
ba9950a73a Use correct value of ansible_distribution in integration tests
This fixes integration tests when run on a RHEL system.  Oddly, the
ansible_distribution='RedHat' when run on RHEL.
2014-03-06 15:52:15 -05:00
James Tanner
85bc14a8eb Remve debug file from vault unit test 2014-03-06 14:49:55 -05:00
Richard C Isaacson
913c855df4 Formatting cleanup.
Post merging of GH-5837 via GH-5749.
2014-03-06 13:08:35 -06:00
g-k-r
dbad5d71c6 modifed test to use get_hosts instead of get_groups
closes #5749

Conflicts:
	test/units/TestInventory.py
2014-03-06 13:06:08 -06:00
g-k-r
6626cb0b3d add test same host in different files in dir
tests issue #5749
 same host defined in different groups which in turn are defined
 in different ini files in an inventory directory

Conflicts:
	test/units/TestInventory.py
2014-03-06 13:03:25 -06:00
James Tanner
cd6d7ddc97 Fix test_async by using env python 2014-03-06 13:32:05 -05:00
Richard C Isaacson
16fe09eef8 Fixes related to uncommenting test_dir_inventory in TestInventory.
0. Uncomment the test.
1. Test fails.
2. Make vars unique per file in test inventory files.
3. Modify token addition to not ast.literal_eval(v) a variable containing a hash.
4. Modify vars to have an escape in test inventory file.
5. Catch exceptions explicitly. Any unknown exceptions should be a bug.
6. Test passes.
2014-03-06 12:09:53 -06:00
Michael DeHaan
94a7fb60fe Allow escaped comments in inventory files. 2014-03-05 20:10:25 -05:00
Richard C Isaacson
b41d8106ff Revert "Merge pull request #6287 from risaacson/fix_hash_in_var"
This reverts commit a808287451, reversing
changes made to 6129ea7566.
2014-03-05 14:49:30 -06:00
Richard Isaacson
a808287451 Merge pull request #6287 from risaacson/fix_hash_in_var
Fix inventory for test_dir_inventory, merge PRs from GH-5749, cleanup some formatting.
2014-03-05 14:20:27 -06:00
James Tanner
6129ea7566 Fixes #6298 and adds a sudo unit test for synchronize 2014-03-05 14:51:40 -05:00
Richard C Isaacson
22a1fb28d6 Minor cleanup. 2014-03-05 13:44:15 -06:00
g-k-r
a3c36a6853 modifed test to use get_hosts instead of get_groups
closes #5749

Conflicts:
	test/units/TestInventory.py
2014-03-05 13:29:47 -06:00
g-k-r
23fee4b836 add test same host in different files in dir
tests issue #5749
 same host defined in different groups which in turn are defined
 in different ini files in an inventory directory

Conflicts:
	test/units/TestInventory.py
2014-03-05 13:27:39 -06:00
Richard C Isaacson
49bd8b0b35 Fix inventory for test_dir_inventory
It came up that fixing this unit test may relate to another ticket that is open. This work allows us to uncomment this unit test by fixing how we pars variables allowing a quoted variable to contain a '#'.

Work also went into cleaning up some of the test data to clarify what was working.

Lastly work went into cleaning up formatting so that the code is easily read.
2014-03-04 18:31:49 -06:00
Jesse Keating
0c2c37a47a Avoid range selection on empty groups
This prevents a traceback when the group is empty.
Fixes #6258
2014-03-03 13:23:27 -08:00
Michael DeHaan
46ec8759d5 Remove the legacy templating code, which was guarded by deprecation warnings in the previous two releases, and undocumented for a long time. use {{ foo }} to access variables instead of ${foo} or $foo. 2014-02-28 18:38:45 -05:00
Michael DeHaan
956eb91de0 Merge pull request #6198 from jlaska/integration_ec2
First pass at ec2 module tests
2014-02-27 10:44:37 -05:00
Chris Church
adeea2c3f3 Added integration test for subversion parameters that need escaping. 2014-02-26 22:44:03 -05:00
James Laska
b589bf1d2e First pass at ec2 module tests 2014-02-26 16:43:30 -05:00
James Tanner
a37a6983be Switch from skipIf to SkipTest for TestVaulLib 2014-02-26 14:01:31 -05:00
James Tanner
f5359c310f Add negative tests for VaultLib 2014-02-26 13:38:58 -05:00
James Tanner
baed7a0ed9 Fixes #6187 Add unit tests for VaultLib 2014-02-26 12:10:09 -05:00
Richard C Isaacson
2bce819519 Fix fails on ubuntu due to missing /etc/motd
Some systems that we are testing on may not have /etc/motd. So we need to create a file that we can control and use that for the further tests.
2014-02-25 13:42:33 -06:00
James Tanner
e121ff111d Fix synchronize unit test to handle checkmode 2014-02-25 09:24:14 -05:00
James Cammarata
f23ccebbdc Merge branch 'issue_4620' of https://github.com/jimi-c/ansible into jimi-c-issue_4620 2014-02-24 20:30:25 -06:00
James Cammarata
7517cd9398 Moving the assemble test to the correct location 2014-02-24 15:19:06 -06:00
James Cammarata
f03d6a67c8 Adding new tests for assemble role 2014-02-24 14:27:23 -06:00
Michael DeHaan
0a83f743c1 Merge pull request #6146 from jlaska/test_synchronize
Correct assert and add with_items test
2014-02-24 15:20:49 -05:00
James Laska
40e0204051 Correct assert and add with_items test 2014-02-24 15:07:23 -05:00
Richard C Isaacson
087f7c230d Typo fixes. 2014-02-24 11:08:21 -06:00
Richard C Isaacson
0446a030d7 Typo fixes. 2014-02-24 11:06:22 -06:00
Richard C Isaacson
dcbc69b69c Added script to the new integration tests. 2014-02-24 10:57:22 -06:00
Richard C Isaacson
e2a47162d0 Added test for failed_when to non_destructive integration tests. 2014-02-24 09:40:44 -06:00
Richard C Isaacson
0c33e936d4 Adding tests for the command and shell modules. 2014-02-23 14:51:26 -06:00
Azul
89cee747d9 replace test 'wget' package with 'hello' package 2014-02-23 10:46:39 +00:00
James Tanner
d29da4cba1 Add iterator tests 2014-02-21 14:26:38 -05:00
James Tanner
65e58c21dd Add test for basic lookups 2014-02-21 11:34:06 -05:00
James Tanner
799fe2c289 Add handlers test 2014-02-21 10:28:27 -05:00
James Tanner
d07032fa5a Add async test role 2014-02-21 10:00:01 -05:00
Michael DeHaan
92feed3851 Update README.md 2014-02-20 19:28:06 -05:00
Michael DeHaan
f0dd040377 reconnect unit tests to 'make tests' 2014-02-20 19:13:27 -05:00
Michael DeHaan
2177b773c8 Rename tests to test, use old directory name. 2014-02-20 19:11:15 -05:00
Michael DeHaan
de600f0040 Move integration tests into tests_new. 2014-02-20 19:10:38 -05:00
Michael DeHaan
379fe02104 Move inventory tests into subdir, prune non-integration tests. 2014-02-20 17:16:58 -05:00
Michael DeHaan
fe7d3773ae Various tests using datafiles are being moved into the integration test framework (tests_new right now).
The unit test infrastructure will remain for things that are mocked out and testable with out filesystem
side effects, and a few cases of things that might not be quite so much (like inventory) that can still
benefit from heavy access to the API.

See the 'tests_new/integration' directory, this will soon fold into tests_new.
2014-02-20 17:16:58 -05:00
Michael DeHaan
0581746a80 Removing tests from units that are now implemented in the new upgraded test system. Once
we're a little further along the units directory will be reserved to pure-API tests.
2014-02-20 17:16:58 -05:00
James Cammarata
701af19fad Removing non-ascii logging test for now 2014-02-20 12:48:59 -05:00
Michael DeHaan
6fb02650ff Remove tests for things that are now using the playbook based 'test_new' infra. Units will remain here
after refactoring, WIP, more to come.
2014-02-19 17:57:39 -05:00
Martin Thorsen Ranang
7e23ed345f Avoid breaking on unicode input when logging to syslog in modules
After commit 254f87e, non-ascii input broke logging to syslog.
2014-02-17 23:56:08 +01:00
James Cammarata
9c9a940af6 Merge branch 'fix-5679' of https://github.com/jirutka/ansible into jirutka-fix-5679 2014-02-17 14:54:29 -06:00
Ilya Kuznetsov
0658847ea6 Allow equal sign in single-line ini variables 2014-02-14 20:04:23 +07:00
Michael DeHaan
c91ceddfac Add the start of an integration test structure using Ansible playbooks, also added an assert action plugin to make writing those easier. 2014-02-13 18:28:29 -05:00
Richard C Isaacson
6feeb16636 Reverting unarchive tests.
We run into some problems because tar --diff will take into account the file ownership and fail if they don't match.

The real-world implication of this is that we could be doing more unarchives then we need to be doing.
2014-02-12 11:26:42 -06:00
Richard Isaacson
eb4a730933 Merge pull request #5969 from risaacson/pull_5136
Updates for the unarchive module and action_plugin.
2014-02-12 10:10:25 -06:00
Richard C Isaacson
598b9c6b7c Cleanup per notes.
Some small changes to per notes from @mpdehann.
2014-02-12 10:01:10 -06:00
Richard C Isaacson
cb7c2b7524 Updates for the unarchive module and action_plugin.
There is a bit going on with the changes here. Most of the changes are cleanup of files so that they line up with the standard files.

PR #5136 was merged into the current devel and brought up to working order. A few bug fixes had to be done to get the code to test correctly. Thanks out to @pib!

Issue #5431 was not able to be confirmed as it behaved as expected with a sudo user.

Tests were added via a playbook with archive files to verify functionality.

All tests fire clean including custom playbooks across multiple linux and solaris systems.
2014-02-12 01:57:00 -06:00
Jacob Weber
35742fe008 Add regex_replace jinja2 filter 2014-02-11 22:02:53 -08:00
James Cammarata
ce0b1a8a96 Fixing tests for git 2014-02-11 12:41:49 -05:00
James Tanner
89c89c8ed2 Re-add synchronize unit tests 2014-02-10 23:56:32 -05:00
James Cammarata
3260e695f4 Make tmp paths in TestRunner dynamic based on pid
Fixes #4723
2014-02-05 23:12:31 -06:00
James Cammarata
ca0ec800d8 Revising method for parsing ranges from --limit subsets
Also added a new test (test_subset_range) for future validation.

Fixes #4620
2014-02-05 13:58:03 -06:00
Jakub Jirutka
012e3ae206 Fixes #5679: lineinfile ignores newline in line argument 2014-01-19 02:24:26 +01:00
jctanner
59d99c17b3 Merge pull request #5337 from bob-smith/bugfixFQDNParsing
Fix inventory parsing so that FQDN can be parsed without throwing ssh port error
2014-01-14 08:28:38 -08:00
Michael DeHaan
8e5b7d3095 Remove code underlying when_* and only_if, which are deprecated features slated for removal in the 1.5 release. 2014-01-03 19:13:21 -05:00
John Barker
4bf9f714d0 Fix inventory parsing so that FQDN can be parsed without throwing ssh
port parsing errors
Fixes problesm introduced by 948d019fef
Adds testcases to defend
2013-12-18 21:33:05 +00:00
Matthew Thode
c0a7f51671 tests depend on the default encoding being utf8
So we set the utils default encoding to be utf8
2013-12-09 12:49:03 -06:00
willthames
40a44ce6ea Ensure test_command tests are actually correct
Using
```
assert 'changed' in result
```
doesn't actually check if something is changed, which is presumably
the reason for the assertion. What is actually needed is
```
assert result.get('changed')
```
which checks that changed is set and not False. Tests still pass after
this change
2013-12-03 12:03:39 +10:00
Eric Johnson
8ff58eb46e fixes #4954 plus updates for gcutil/v1beta16 tests 2013-11-19 22:30:22 +00:00
Rene Moser
b5580389f6 host: added test playbook 2013-11-15 18:35:45 +01:00
James Tanner
4391cbfd91 Fix git bare test in el6 by adding origin to remote 2013-11-14 14:42:07 -05:00
jctanner
ad5012f930 Merge pull request #4691 from cg-soft/git-bare-ref-repo-support
Add support for bare git reference repos
2013-11-14 10:39:57 -08:00
James Tanner
9e197d3958 Fix bool comparision in recursive copy tests 2013-11-13 16:51:11 -05:00
James Tanner
33242cacf3 Merge pull request #4375 from pfalcon/ansible
copy: Implement recursive copying if src is a directory.
2013-11-13 15:52:40 -05:00
jctanner
9a7765daf7 Merge pull request #4351 from 2m/leading-range-fix
Allow leading ranges in the inventory host entries.
2013-11-13 10:48:57 -08:00
Christian Goetze
f41d4ac390 Add support for bare git reference repos
This adds two parameters to the git module:

  bare (boolean)
    Indicates this is to be a bare repositori

  reference (string)
    Indicates the path or url to the reference repo.
    Check out the "--reference" option in the "git clone"
    man page

Added appropriate tests.
2013-10-31 10:56:14 -07:00
James Tanner
d154bf8781 Revert templating enhancements from 73dbab70 e6c28658 d409352c 9858b1f2 4587528b 9b1fe455 214b0b05 8d3db803 7f9504d1 5031104c 35cb9dc2 2bd8cb57 1e85c754 2013-10-30 10:50:16 -04:00
Michael DeHaan
603db60828 Merge pull request #4288 from sivel/3725-regex
Add regex (search, match, regex) jinja2 filters. Fixes #3725
2013-10-27 08:48:12 -07:00
Michael DeHaan
3778b39115 Merge pull request #4380 from joshkehn/lineinfile_validate
Added validate option to lineinfile
2013-10-27 08:46:47 -07:00
Michael DeHaan
5031104c3a Finishing touches on template cleanup. 2013-10-19 11:40:48 -04:00
Michael DeHaan
35cb9dc22f Work in progress about cleaning up template code. 2013-10-19 11:39:52 -04:00
Michael DeHaan
baa13a5cc7 Merge pull request #4395 from erjohnso/devel
adding Google Compute Engine modules and inventory plugin
2013-10-17 07:30:55 -07:00
Martynas Mickevicius
7ecb5fbc9c Handle comment on inventory group line. 2013-10-17 13:16:35 +03:00
Martynas Mickevicius
44279ce34f Allow leading ranges in the inventory host entries. 2013-10-17 13:16:35 +03:00
Jascha Geerds
76ed19d279 Fix TestInventory class by explicitly using /bin/bash 2013-10-15 21:34:36 +02:00
Paul Sokolovsky
3ad61ef310 copy: Add testcase for recursive copy. 2013-10-15 18:40:40 +03:00
Michael DeHaan
43df00550d Merge pull request #3827 from mscherer/disable_callbacks
add a way for callback to disable itself
2013-10-12 07:03:06 -07:00
Michael DeHaan
2032489617 Prune legacy tests -- many of these are not part of the official API or documented syntax. 2013-10-11 19:31:26 -04:00
Michael DeHaan
e8b043332f Remove some obsolete tests (mechanism of error detection suboptimal, replacements pending) 2013-10-11 19:28:53 -04:00
Michael DeHaan
add45d2ca9 Fixup legacy var detector. 2013-10-11 19:16:36 -04:00
Michael DeHaan
709ffda3d1 Tweak only_if deprecation detector. 2013-10-11 19:12:25 -04:00
Michael DeHaan
25dc0ef8d7 Remove out of date tests. 2013-10-11 19:09:10 -04:00
Michael DeHaan
800f12618e Remove out of date tests. 2013-10-11 19:08:53 -04:00
Matt Martz
61525a97df Add regex (search, match, regex) jinja2 filters. Fixes #3725 2013-10-11 08:03:04 -05:00
Eric Johnson
9ca824c16d adding Google Compute Engine modules and inventory plugin 2013-10-07 21:01:37 +00:00
Michael DeHaan
8fc46a3a5a Return inventory objects in the order they are presented. Additionally, fix host slicing such that it works on Python terms with
zero indexed lists and a non-inclusive final element.
2013-10-07 15:06:15 -04:00
Joshua Kehn
cc0c908cee Added validate option to lineinfile
The validate option is constructed similarly to the template command's
validate option. TestRunner.py has been updated to include two new
tests, one for passing and one for failing validation.
2013-10-06 13:51:27 -04:00
Matt Martz
535ce97067 Add fileglob Jinja2 filter. Fixes #3563 2013-09-30 12:55:13 -05:00
Michael DeHaan
ef28d62846 Update TestUtils.py
tests shouldn't be making symlinks to system dirs, also fixes unit test report on OS X.
2013-09-28 11:01:21 -04:00
Jasper Capel
d4dec5f577 Allow creating empty inventory
Instantiating the Inventory class with host_list=None now results in an
empty inventory instead of an error.
2013-09-25 15:00:35 +02:00
Michael Scherer
399d57a651 add more tests :
- test part of ansible.runner.filter_plugins.core
 - test ansible.utils.unfrackpath
2013-09-21 13:00:11 +02:00
James Cammarata
3b801dec72 Merge branch 'failed_when' of https://github.com/hnakamur/ansible into hnakamur-failed_when 2013-09-16 07:35:34 -05:00
James Cammarata
aac3090909 Merge branch 'play_remote_user' of https://github.com/bcoca/ansible into bcoca-play_remote_user 2013-09-16 05:55:14 -05:00
Hiroaki Nakamura
2357194b39 Add failed_when module variable.
Implementation note: Ternery operator trick for python prior to 2.5 is used.
(test and [when_true_value] or [when_false_value])[0]
http://stackoverflow.com/questions/394809/ternary-conditional-operator-in-python#comment1466794_394887
2013-09-10 08:34:01 +09:00
James Cammarata
8d0487c31e Removing broken tests for now 2013-09-09 15:16:17 -05:00
Brian Coca
d47c48e30a Added remote_user to plays
Still compatible with user: but deprecating it so we can have
a matching remote_user: in tasks, cannot be user: because of the
module of the same name. #3932

Signed-off-by: Brian Coca <briancoca+dev@gmail.com>
2013-09-07 16:34:22 -04:00
Michael Scherer
a0b73b18c3 add one last test, for combined range, which make ansible.inventory.expand_hosts
covered to 100%
2013-08-23 13:06:31 +02:00