Michael DeHaan
0c4b30a471
Aliased node test doesn't make sense locally, so remove it.
12 years ago
Michael DeHaan
9985995a9d
Make tests use the local connection type, fix missing callback in tests.
12 years ago
Daniel Hokka Zakrisson
eebbbd3f0e
Make parameterized playbook includes work with vars as a list
...
Fixes #1610 .
12 years ago
Daniel Hokka Zakrisson
5752d2a850
Fix lookup plugin test properly
12 years ago
Daniel Hokka Zakrisson
f91fa9f765
Fix lookup plugin test
12 years ago
Daniel Hokka Zakrisson
9c095b72b9
Add parameterized playbook includes
...
Also makes with_* work with them.
Fixes #1162 .
12 years ago
Daniel Hokka Zakrisson
43419d7b20
Add tests for lookup plugins
12 years ago
Daniel Hokka Zakrisson
40af8eff14
Add testcase for first_available_file
12 years ago
Daniel Hokka Zakrisson
fbda2d4628
Use default port if ansible_ssh_port is not set for the delegated node
...
Also add testcase for it.
12 years ago
Michael DeHaan
6ba30170dd
Make group_vars and host_vars available to usr/bin/ansible, and make vars_plugins exist
12 years ago
Daniel Hokka Zakrisson
1449c8ac67
Fix ansible_ssh_host again
...
This time with unit tests to ensure it keeps working.
12 years ago
Michael DeHaan
e1ecb95b3d
Delete test that was coded against *local* resolv.conf -- obviously not going to be the same between people's computers
12 years ago
Michael DeHaan
08b70949c7
Fix a test and a typo in an example
12 years ago
John Kleint
2a002f5c0b
Support iteration over command output in with_items.
...
When the output of a command is stored in a register, this will create a
stdout_lines field in the result object that contains stdout split into a list
of lines. This list can then be iterated over using with_items.
12 years ago
Michael DeHaan
04555f525e
Fix a test from a previous pull request.
12 years ago
Brian Coca
83d1028a21
- Makefile now works with freebsd (date command options are diff)
...
date still issues warning and ignores TZ
- Updated tests to work inside bsd jails (127 addresses are an issue)
Signed-off-by: Brian Coca <briancoca+ansible@gmail.com>
12 years ago
Dave Peticolas
b42e835aab
Always load group_vars and host_vars.
12 years ago
Dave Peticolas
08272dc25d
Remove unused imports.
12 years ago
Michael DeHaan
1c9b43df1b
more whitespace
12 years ago
Petros Moisiadis
2ac4acbf97
fixes for tests
13 years ago
Will Thames
845a7ac5ae
test_one not working as tests after skipped test failing, because
...
on_skipped callback being passed an extra item parameter that it wasn't
expecting.
Fixed it so that on_skipped in TestCallbacks accepts and ignores the
extra parameter
Extra parameter was added in 4b9b9a8a5b
but not really clear why from commit message
13 years ago
Michael DeHaan
867b2437cc
consolidate output code in callbacks.py, from utils, remove extra functions
13 years ago
Michael DeHaan
279b5965b8
Much streamlining around setup steps in playbooks, now only run setup once per play.
13 years ago
Michael DeHaan
efac68b636
Remove the -D module debug flag, which no longer is functional due to sudo pty requirements, and replace with -v/--verbose.
...
This flag will show playbook output from non-failing commands. -v is also added to /usr/bin/ansible, but not yet used.
I also gutted some internals code dealing with 'invocations' which allowed the callback to know what module invoked
it. This is not something 0.5 does or needed, so callbacks have been simplified.
13 years ago
John Kleint
70837469c6
Properly template list of hosts in playbooks.
...
In playbooks, hosts can be a YAML list. We templated the list before
converting it to a semicolon-separated string, which actually templated its
repr. This converts to a string first. A basic unit test is included.
13 years ago
Michael DeHaan
d4f660edc3
Do not run unit tests against the EVENTS code because it is subject to change and that does not mean anything is broken.
...
If we want to test playbooks, it's best to test the result of a playbook to make sure it does the correct thing. Also
remove playbook2/3 yml which were not used.
13 years ago
Jeroen Hoekx
cd9f926b5f
Fix correct variable expansion in includes only_if.
...
There's not need to run the complete include through the templating engine.
Several variables were not included before the conditional was evaluated.
13 years ago
Jeroen Hoekx
029fe1273c
Modify /usr/bin/ansible and playbooks to use the new async API.
13 years ago
Michael DeHaan
b9982fc17b
Reinstate --extra-vars, which can do things in playbooks like:
...
ansible-playbook release-my-app.yml --extra-vars="version=123"
And make $version available in the playbook without re-editing the file
13 years ago
Michael DeHaan
c0c691089d
Fix bug in src. Should not code this early :)
13 years ago
Michael DeHaan
3f26a1c7f6
verbose option is not being used, so remove it. debug variable still exists.
13 years ago
Michael DeHaan
08c593bee1
Warn if no hosts matched
13 years ago
Michael DeHaan
b9e3b053f9
Simplify playbook tests so things are not timing dependent in the poll section, which is leading to tests
...
not being consistent between runs, even though there wasn't an error. Now we'll just check the final change
counts, which should be just as solid and lead to less churn in the events file.
13 years ago
Michael DeHaan
e103bdda93
Rename test class to match what it is testing
13 years ago
Michael DeHaan
4792021f47
Fix syntax error in user patch
13 years ago
Michael DeHaan
2511992659
Surface module debug (-D) to /usr/bin/ansible also
13 years ago
Michael DeHaan
6dda6f12dc
Applying callback model to runner, and using that in playbooks, so output can be more immediate in playbooks.
...
(Runner still does not use callbacks for default output)
13 years ago
Michael DeHaan
6ab615c724
Code cleanup for playbooks, also added 'on_skipped' callback
13 years ago
Michael DeHaan
a5f4ca50b8
Ratchet up logging a few notches prior to controlling w/ verbosity settings
13 years ago
Michael DeHaan
b5c62ec068
Enhance logging, way to gate verbosity levels pending.
13 years ago
Michael DeHaan
4de7bbb169
Allow conditional imports, see examples/playbook3.yml comments for a full explanation. Extensive
...
refactoring of playbooks now warranted, which we'll do before we move on. This variable assignment
system makes nearly all possible magic possible, for we can use these variables however we like,
even as module names!
13 years ago
Michael DeHaan
c1fe0dd719
Quote long variables in playbooks when feeding them to the setup command
13 years ago
Michael DeHaan
5371a9e497
Regression tests for playbooks, logging the events they call via callbacks.
13 years ago
Michael DeHaan
b15c8e9cb1
Playbook test upgrades, made some notes about callbacks we need to add. Still need to compare events
...
recieved vs expected so we can be notified if this test breaks, and also to add some more detailed
playbooks that use includes & async, etc.
13 years ago
Michael DeHaan
45abe3c16b
Add unit tests for playbooks, and fix an error caught by one
13 years ago