Commit graph

2731 commits

Author SHA1 Message Date
Matt Clay
cd3a795e65 Permissions fix for remote coverage downloads. 2017-07-02 14:09:16 -07:00
Matt Clay
554423cf04 Expose docker socket to test containers. 2017-06-30 16:46:41 -07:00
Matt Clay
7ab4a889ad Update tox.ini to use ansible-test. 2017-06-30 16:41:30 -07:00
René Moser
77d0542985 test, integration: add diff support (#26296) 2017-06-30 20:43:34 +02:00
Pierre-Louis Bonicoli
d08ff86169 ansible-test: pass --[skip-]tags to ansible-playbook
Thanks to Olaf Klischat for the idea.
2017-06-30 10:35:39 -07:00
Abhijeet Kasurde
f0a5854e39 Fix unresolved import in vmware module_utils (#25288)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-30 10:28:08 -04:00
Abhijeet Kasurde
5c374cd1ae Add Test Suite for vmware_vswitch (#26076)
Fix adds test suite for vwmare_switch

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-30 10:18:20 -04:00
Abhijeet Kasurde
69e55b2cfe Add testsuite for VMware Distributed vSwitch (#26193)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-30 10:16:48 -04:00
Abhijeet Kasurde
28fcfcdbef Add testsuite for vmware cluster (#26281)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-30 10:15:58 -04:00
Trishna Guha
93bbcd8a32 vyos_user fix idempotent (#26289)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2017-06-30 19:44:08 +05:30
Toshio Kuratomi
34589cee6d Unittests for extracting metadata from plugins (#26218)
* Unittests for extracting metadata from plugins
* Port plugin_docs to use the generic extract_metadata function
* Make the helper functions seek_end_of{string,dict} private
2017-06-30 06:48:32 -07:00
Rob
d1652aecf0 Upgrade ec2_remote_facts to use boto3 (#22937)
* Deprecate ec2_remote_facts in favor of ec2_instance_facts which uses boto3

* Update legacy-files.txt with deprecated file name change
2017-06-30 14:19:08 +10:00
Abhijeet Kasurde
bc4ff8aed9 Modify flask_control for vmware_host test suites (#26175)
Fix adds additional helper methods to get information about
host system from vcsim

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-29 19:11:28 -04:00
Matt Clay
17c1bb6f08 Remove legacy integration test make targets. (#26255)
* Remove legacy integration test make targets.
* Remove incorrect role path from cloudscale test.
2017-06-29 12:34:54 -07:00
Mike Wiebe
240de965ee Fix nxos_acl module and add IT tests (#25966)
* Fix nxos_acl module and add IT tests

* Add nxos_acl test

* Add additional properties to test
2017-06-29 14:55:08 -04:00
Alexander Braverman
038e090bc1 Add sshpass to Dockerfile for Ansbile integration tests 2017-06-29 08:56:41 -07:00
David Newswanger
9500aac5b9 added integration tests for dpkg_selections (#26043) 2017-06-29 15:53:42 +01:00
Nathaniel Case
3102746ebe nxos_pim_rp_address fixes (#26119)
* nxos_pim_rp_address tests

* nxos_pim_rp_address changes

* Address issues with idempotence
2017-06-29 10:22:26 -04:00
Ricardo Carrillo Cruz
8a1cd05fdc Assert vyos_user commands output against first element of array (#26233) 2017-06-29 13:51:13 +02:00
Ricardo Carrillo Cruz
c8ba8bdd6d Add ios_static_route module (#25527)
* Add ios_static_route module

* Add ios_static_route integration tests

* Add platform agnostic integration tests for IOS

* Replace unicode function to ansible module_utils to_text

* Add collections handling logic

* Add integration tests for collections

* Make collections and prefix mutually exclusive

* Add net_static_route integration tests for collections

* Do not store load_config return value, as it returns nothing
2017-06-29 12:05:20 +02:00
David Newswanger
5242ff1b59 added integration tests for rpm_key (#26134) 2017-06-29 09:46:42 +01:00
Ganesh Nalawade
911a7e085e Add active param to junos declarative modules (#26222)
*  active/deactivate configuration capability
*  integration test refactor
2017-06-29 10:18:35 +05:30
Trishna Guha
15e78d1073 fix iosxr_user integration test (#26220)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2017-06-29 09:20:12 +05:30
Nathaniel Case
ad6c4a544e nxos_pim updates (#26145)
* nxos_pim tests

* Cleanup nxos_pim
2017-06-28 19:40:19 -04:00
Nathaniel Case
eea18e9875 nxos_vxlan_vtep_vni fixes (#25913)
* nxos_vxlan_vtep_vni first pass
* nxos_vxlan_vtep_vni tests
2017-06-28 19:38:31 -04:00
Jordan Borean
98fc54f02d win_find: fix for empty nested directories (#26164) 2017-06-29 07:06:10 +10:00
Dag Wieers
0a15ab7ce9 win_say: Fix issue, add integration tests (#26089)
* win_say: Fix issue, add integration test

This PR includes:
- Make speed_speech an integer parameter
- Test for empty parameters too
- Add integration tests

* Improve the $speech_speed parameter handling

As requested
2017-06-29 06:28:44 +10:00
David Moreau-Simard
9fdd07fba8 Provide the list of files that were included by include_vars
include_vars will now also return a key 'ansible_included_var_files'
which contains the list of files that were successfully loaded.
This is useful information and, amongst other things, a way for users
to know exactly what files were included when debugging their
playbooks.
This also allows us to improve the integration tests around
include_vars.
2017-06-28 15:25:45 -04:00
Abhijeet Kasurde
bb847e332d Check if SELinux is installed on system (#24437)
* Refactor code
* PEP8 fixes
* Check if /etc/selinux/config file exists before
  proceeding any other operations

Fixes #21622

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-28 19:39:52 +01:00
Dag Wieers
5be32aa5af Move ping and win_ping closer together (#26028)
So in an effort to verify if Windows modules are feature complete
compared to the python equivalent, I stumbled upon these differences.

This PR includes:
- Add missing 'data' option from documentation
- Simplify ping module
- Update integration tests to test exception
2017-06-28 11:08:04 -07:00
Tim Rupp
e7402e3d5b Support full path templates (#26121)
This patch allows the iapp service module to support full path
templates instead of only relative templates
2017-06-28 17:35:00 +01:00
Tim Rupp
04ac15f241 Adds bigip_qkview module (#25980)
This module can be used to generate qkviews on a bigip and
save them to a location on the ansible controller.
This module is primarily used for diagnostics.

Unit tests are provided. Integration tests can be found here

https://github.com/F5Networks/f5-ansible/blob/devel/test/integration/bigip_qkview.yaml#L23
https://github.com/F5Networks/f5-ansible/tree/devel/test/integration/targets/bigip_qkview/tasks
2017-06-28 17:31:17 +01:00
Tim Rupp
16bd93a14e Refactors bigip ssl cert module (#25882)
Includes unit tests and a refactor of the module to make code
more easily supported. Also fixes an issue where the extension of
the cert name was not appended if not provided. This problem was
causing certs to not be editable in the UI. Also deprecates params.

Unit tests are provided. Integration tests can be found here

https://github.com/F5Networks/f5-ansible/blob/devel/test/integration/bigip_ssl_certificate.yaml#L23
https://github.com/F5Networks/f5-ansible/tree/devel/test/integration/targets/bigip_ssl_certificate/tasks
2017-06-28 17:26:39 +01:00
Matt Clay
55aec8ebc9 Limit yamllint version on python 2.6. 2017-06-28 08:35:19 -07:00
Trishna Guha
be11d12fa2 fix vyos_user integration test assert (#26185)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2017-06-28 16:17:03 +01:00
George Nikolopoulos
11836a0296 Add module netscaler_cs_action (#26147) 2017-06-28 19:16:46 +05:30
Trishna Guha
9a88c157ec add vyos, openvswitch to network-all playbook (#26167)
* add vyos to network-all playbook

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>

* Add opensvwitch to network-all

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2017-06-28 13:27:55 +05:30
Trishna Guha
34eca3816d fix vyos_user configuration (#26166)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
2017-06-28 12:13:27 +05:30
Ganesh Nalawade
3bd8dbb53d Add support for netconf network discovery (#25435)
* Add support for netconf network discovery

* Fix unit test failure
2017-06-28 11:07:38 +05:30
Dag Wieers
bb7ebc6a55 win_msg: Added integration tests, parameter fixes (#26126) 2017-06-28 10:35:38 +10:00
Dag Wieers
fceb71128e Return code is not very useful to assume a task failed
So I thought I fixed it before, but there's still one location where
the `rc` value is influential to decide whether a task failed or not.

We already established in #24867 that it is up to the module to decide
what the return code actually means, not the task executor. We modified
the existing modules to move that logic into the module (eg. for
command, shell, etc.)

This relates to the integration tests of win_robocopy, where different
return codes have different meanings:

  - 0  --  No files copied.
  - 1  --  Files copied successfully! (changed)
  - 2  --  Some Extra files or directories were detected. No files were copied. (warning)
  - 3  --  (2+1) Some files were copied. Additional files were present. (changed)
  - 4  --  Some mismatched files or directories were detected. Housekeeping might be required!  (changed + warning)
  - 5  --  (4+1) Some files were copied. Some files were mismatched.  (changed + warning)
  - 6  --  (4+2) Additional files and mismatched files exist.  No files were copied. (warning)
  - 7  --  (4+1+2) Files were copied, a file mismatch was present, and additional files were present. (changed + warning)
  - 8  --  Some files or directories could not be copied! (changed + failed)
  - 9 - 15  --  Fatal error. Check log message! (failed)
  - 16  --  Serious Error! No files were copied! Do you have permissions to access $src and $dest? (failed)

This also fixes #24652
2017-06-27 15:40:27 -04:00
George Nikolopoulos
6bed831f8c Add netscaler_server module (#25537) 2017-06-27 23:08:00 +05:30
Abhijeet Kasurde
96dcd1060c Add testsuite for vmware_datacenter (#26133)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-27 13:19:17 -04:00
Nathaniel Case
3d6d428bbc Test multiple nxos versions at once (#25595)
* Extend tests to have multiple device representations

* Move filepath munging to nxos_module

* Device needs to be kwarg so we can leave it off

* Update other nxos tests

* Update tests that fell through
2017-06-27 12:45:36 -04:00
Abhijeet Kasurde
79b2897462 Update vmware_guest_find module (#26066)
Fix updated following:
* Update Documentation
* Update Examples
* Find VM's folder using VM's UUID
* Make name as optional parameter

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-27 11:58:57 -04:00
Ricardo Carrillo Cruz
9f7fcf15be Add missing quote on limit_to vyos includes (#26139) 2017-06-27 16:01:54 +02:00
Toshio Kuratomi
e238ae999b Cyptography pr 20566 rebase (#25560)
Make pyca/cryptography the preferred backend for cryptographic needs (mainly vault) falling back to pycrypto

pyca/cryptography is already implicitly a dependency in many cases
through paramiko (2.0+) as well as the new openssl_publickey module,
which requires pyOpenSSL 16.0+. Additionally, pyca/cryptography is
an optional dep for better performance with vault already.

This commit leverages cryptography's padding, constant time comparisons,
and CBC/CTR modes to reduce the amount of code ansible needs to
maintain.

* Handle wrong password given for VaultAES format

* Do not display deprecation warning for cryptography on python-2.6

* Namespace all of the pycrypto imports and always import them

  Makes unittests better and the code less likely to get stupid mistakes
  (like using HMAC from cryptogrpahy when the one from pycrypto is needed)

* Add back in atfork since we need pycrypto to reinitialize its RNG just in case we're being used with old paramiko

* contrib/inventory/gce: Remove spurious require on pycrypto

(cherry picked from commit 9e16b9db275263b3ea8d1b124966fdebfc9ab271)

* Add cryptography to ec2_win_password module requirements
  * Fix python3 bug which would pass text strings to a function which
    requires byte strings.

* Attempt to add pycrypto version to setup deps

* Change hacking README for dual pycrypto/cryptography

* update dependencies for various CI scripts

* additional CI dockerfile/script updates

* add paramiko to the windows and sanity requirement set

  This is needed because ansible lists it as a requirement. Previously
  the missing dep wasn't enforced, but cryptography imports pkg_resources
  so you can't ignore a requirement any more

* Add integration test cases for old vault and for wrong passwords

* helper script for manual testing of pycrypto/cryptography

* Skip the pycrypto tests so that users without it installed can still run the unittests

* Run unittests for vault with both cryptography and pycrypto backend
2017-06-27 06:00:15 -07:00
Abhijeet Kasurde
e7e091d154 Update Flask controller for latest testsuites (#26125)
Fix adds GPL Licence and few improvements to accommodate
new testsuites.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
2017-06-27 08:08:47 -04:00
Matt Davis
36ad934156 re-enable non-pipelined mode for Powershell (#25012)
* fixes #23986
* fixes 3rd-party Windows connection plugins that don't support pipelining (eg awsrun)
2017-06-26 22:58:09 -07:00
Jordan Borean
b41c42cf0d win_share: Add integration tests and various fixes (#25691)
* win_share: Add integration tests and various fixes

* docs and comments updates based on PR review

* fixed up documentation issue with URL
2017-06-27 12:07:22 +10:00