Commit Graph

5102 Commits (837aada4a8564f034b55204fa2e58569b82427bc)

Author SHA1 Message Date
Matt Clay af15a46f20 Disable unstable ec2_vpc_subnet test. 7 years ago
Matt Clay 97942a588a Disable unstable ec2_vpc_route_table test. 7 years ago
zikalino 7284d40049 trying to fix storage blob timing issue 7 years ago
Sam Doran 00068e9fcc
Add integration tests for include_role using variable for tasks_file (#37742)
* Add tests using a variable in tasks_from field

Related to #32503

* Do not test using hostvars with import_role

hostvars cannot be used with import_role — use include_role instead
7 years ago
Alex Tsitsimpis c3ab6cb9b1 template: Add option to `lstrip_blocks' and fix setting`trim_blocks` inline (#37478)
* template: Add integration tests for `lstrip_blocks'

Signed-off-by: Alex Tsitsimpis <alextsi@arrikto.com>

* template: Fix passing `trim_blocks' inline

Fix passing `trim_blocks' option to the template module as inline
argument. Previously passing the `trim_blocks' option inline instead of
using the YAML dictionary format resulted in it always being set to
`True', even if `trim_blocks=False' was used.

Signed-off-by: Alex Tsitsimpis <alextsi@arrikto.com>

* template: Add option to `lstrip_blocks'

Add option to set `lstrip_blocks' when using the template module to
render Jinja templates. The Jinja documentation suggests that
`trim_blocks' and `lstrip_blocks' is a great combination and the
template module already provides an option for `trim_blocks'.

Note that although `trim_blocks' in Ansible is enabled by default since
version 2.4, in order to avoid breaking things keep `lstrip_blocks'
disabled by default. Maybe in a future version it could be enabled by
default.

This seems to address issue #10725 in a more appropriate way than the
suggested.

Signed-off-by: Alex Tsitsimpis <alextsi@arrikto.com>

* template: Add integration tests for `trim_blocks'

Signed-off-by: Alex Tsitsimpis <alextsi@arrikto.com>

* template: Check Jinja2 support for `lstrip_blocks'

Since the `lstrip_blocks' option was added in Jinja2 version 2.7, raise
an exception when `lstrip_blocks' is set but Jinja2 does not support it.
Check support for `lstrip_blocks' option by checking `jinja2.defaults'
for `LSTRIP_BLOCKS' and do not use `jinja2.__version__' because the
latter is set to `unknown' in some cases, perhaps due to bug in
`pkg_resources' in Python 2.6.6.

Also update option description to state that Jinja2 version >=2.7 is
required.

Signed-off-by: Alex Tsitsimpis <alextsi@arrikto.com>
7 years ago
Martin Krizek 00d9345158
apt: mark installed packages manual (#37751)
* apt: mark installed packages manual

* Add fallback for when manual is not a thing
7 years ago
Matt Clay 0dade18f43 Fix yamllinter handling of tuple assignment. 7 years ago
zikalino 503f907b63 fix container instance version 7 years ago
Pierre-Louis Bonicoli 2a7481444b supervisorctl: add integration tests 7 years ago
Matt Clay 4e0ecfd553 Fix ansible-test handling of network plugins. 7 years ago
Toshio Kuratomi 0633f73faf Fix loader for filters (#37748)
* Fix loading of filter and test plugins

Filter and test plugins are different than other plugins in that they
can have many plugins in a single file.  Therefore they need to operate
a little differently.  They need to have all of the potential files
returned.  Then the caller takes care of passing those onto jinja2 in
order for jinja2 to make use of them.

This problem was (most recently) introduced with f921369445

This commit also restructures how we deduplicate plugins to take paths
into account.  If we want to start scoping which set of modules are
loaded (due to roles, for instance) we'll need to hang on to the path
information.

* add integration test for override

* Fix style checks for bcoca code

* Implement jinja2 plugin loader as a subclass

Having a subclass allows us to customize the overriding of jinja
plugins.  We can then move common parts of common code into the Loader.
7 years ago
Sloane Hertel da3f7a8db1 [cloud] ec2_vpc_route_table: ignore routes without DestinationCidrBlock - fixes #37003 (#37010)
* [cloud] ec2_vpc_route_table: ignore routes without DestinationCidrBlock

Add module warnings rather than silently skipping

* Permit warnings for routes tables containing vpc endpoints to be turned off

* Add tests to ensure a VPC endpoint associated with a route table does not result in a traceback
7 years ago
Matt Clay f1899f784b Fix docker_secret test on RHEL. 7 years ago
Sloane Hertel f53f29352d Move AWS placebo fixtures into test/units/utils so module_utils tests can use them (#37300) 7 years ago
Martin Krizek 296ad80002
apt: allow for integration tests using fake repo (#37639)
* apt: allow for integration tests using fake repo

* Add integration test for 19102

* Clean up packages and repo

* Fix indentation
7 years ago
Martin Krizek ab1db9bcb8 yum: clean fake repos after tests run (#37770) 7 years ago
Matt Clay ee596743d1 Improve ansible-test retries. 7 years ago
Zim Kalinowski fcd75bbc5a fixing function app test (#37687) 7 years ago
Matt Clay c7701fd4ac Disable failing azure_rm_securitygroup test. 7 years ago
Dag Wieers 2c2f335893
win_psexec: Fix pslint issues (#37718) 7 years ago
Dag Wieers de5fb66026
win_product_facts: Fix pslint issues (#37722) 7 years ago
Zim Kalinowski fef5f01b11 adding possibility to specify resource group for referred virtual net… (#36768)
* adding possibility to specify resource group for referred virtual network

* fixed sanity issues

* removed trailing whitespace

* added test

* fixed documentation

* try to fix unstable test

* Tidied up the description of virtual_network_resource_group
7 years ago
Zim Kalinowski 0b828ee830 azure_rm_virtualmachine: adding possibility of disabling public ip address (#36766)
* adding possibility of disabling public ip address

* fixed indent

* fixed whitespace

* fixed mistake

* try to create test with vm without public ip address

* try to fix test

* another attempt for test

* fixing test

* create vm with no ip with different name and delete it immediately

* a few additional fixes

* another attempt to pass test

* must be deleted

* simplified no ip test

* reorganised tests

* Wrapped choice in C()
7 years ago
Zim Kalinowski 89401f13f7 azure_rm_networkinterface: fixed issue when public ip address should not be created (#36824)
* fixed issue when public ip address should not be created

* adding test for public ip address

* fixed samples

* another fix to sample formatting

* fixed test

* fix test

* fixed test

* another attempt to fix test

* maybe it works now

* still wrong

* improved check per customer request

* removed stupid semicolon

* updated test to match main scenario

* changed ip configurations to list

* another attempt
7 years ago
Dag Wieers fdc0e5c5fb
win_defrag: Fix pslint issues (#37719) 7 years ago
Dag Wieers f78b415db0
win_wakeonlan: Fix pslint issues (#37717) 7 years ago
Matt Clay c73ee8aac8 Update httptester SHA. 7 years ago
Matt Clay 307d8b5330 Disable PowerShell null comparison test.
Too many false positives due to unknown types.
7 years ago
Matt Clay 05220d693d
Complete updates of remaining code-smell tests. (#37743)
* Add text/binary file support to code smell tests.
* Enhance line-endings code smell test.
* Enhance no-smart-quotes code-smell test.
* Enhance shebang code-smell test.
7 years ago
Matt Martz 7c311ad615 Update httptester for httpbin==0.6.2 7 years ago
Matt Clay 6352e67ab2 Update ansible-test is_binary_file test.
Add hard-coded list of common text and binary extensions.
7 years ago
Matt Clay aee01564a9 Clean up non-standard module shebangs. 7 years ago
Abhijeet Kasurde 0ae7a0e88c
VMware: Use environment variable for connection (#37726)
This fix adds environment variables for connection in vmware_*
modules.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Matt Clay 8daa80e5bb Move var precedence check to integration tests. 7 years ago
Alexander Bethke eebe728ae8 Fix SteamOS ansible_distribution fact (Fixes #33628) (#37576)
Fixes #33628
7 years ago
Julien Vey ec2e027980 cloudfront_distribution: fix the order of headers to avoid updates again and again (#37340)
* Fix python2/3 compatibilities issues

* Sort cloudfront_distribution headers to avoid useless updates
7 years ago
Matt Clay 248ca2df21 Fix encoding of code-smell paths on stdin. 7 years ago
zikalino fa2ff6ceaa enabling storage blob as it seems that test is stable 7 years ago
Matt Clay 51e3882b80 Update tests triggered for `bin/` changes. 7 years ago
Matt Clay 97670c4a82 Update ansible-test default container SHA. 7 years ago
Im0 8c4f349743 Test include role with items in name #36372 (#37001)
* Tests for #36372

* Tests for #36372

* Tests for #36372
7 years ago
Izuke e02c72d856 Fixes #32146 Fixes reconcile inventory to correctly remove hosts from ungrouped 7 years ago
Matt Clay 775539a8b8 Fix api_profile choices in Azure docs fragment. 7 years ago
Matt Clay f11986c82a
Update default ansible-test docker container. (#37644)
* Limit cryptography version for Python 2.6 tests.
* Specify pip list format to eliminate warning.
7 years ago
Matt Clay 8232c95f42 Pin httptester SHA. 7 years ago
Aleksander Kovtunenko f51a6ea832 implemented installroot option (#33613)
* fix

* move version to 2.6
7 years ago
Samer Deeb a89bafce2e issue:37306 Fix issue with vlan support for onyx version 3.6.6000 (#37310)
* issue:37306 Fix issue with vlan support for onyx version 3.6.6000

Signed-off-by: Samer Deeb <samerd@mellanox.com>
7 years ago
Claes Nästén 6308047dc9 nso_verify handle leaf-list in 4.5 and identityref (#37393)
NSO verify did not handle leaf-list value verification in 4.5 and
later due to changes made for configuration writing made.

map prefix for identityref types in verification.
7 years ago
Matt Clay 1fd9a616a4 Fix uri test on Python 2.6. 7 years ago
Claes Nästén 458a07d5a4 add timeout parameter and increase default timeout for nso modules (#37391)
NSO operations can take much longer than 10 seconds as they operate on
real network equipment, set default timeout to 5 minutes and allow for
user override.
7 years ago
Adrian Likins e166946a0a Fix redundant yaml error blurbs on ModArgs parse errors (#36923)
* Fix redundant yaml error blurbs on ModArgs parse errors

Some of the AnsibleParserErrors from parsing.mod_args
are created with the obj=some_yaml_ds options but
some are not.

If they were, we don't want to add another yaml_ds to
it, because that will result in double yaml error blurbs.
And since we dont need to add info, we can just re raise it.

But if there is no ._obj, add it here so we get the extra
detail in the error message (see issue #14790) and raise
a new AnsibleParserError instance.

Fixes #36848

* cleanup existing test_tasks pep8/sanity issues
7 years ago
Claes Nästén f8d20f970f Update Cisco NSO module required versions. (#36736)
NSO modules will now work with older versions of NSO, update version
requirements.
7 years ago
Julien Vey 26d9de6f3e apt_repository: check attribute repo for None value (#36944) 7 years ago
Dag Wieers 51662acc6c
Clean up Grafana docs a bit (#37516)
* Clean up Grafana docs a bit

But more is needed, default values, missing choices, proper
descriptions, actual sentences :-)

* Remove validate-modules entries
7 years ago
Ryan Petrello 872a7b4a7a add some Tower module integration tests (and fix a bug or two) (#37421)
* add additional test coverage for tower modules

* add test coverage for the tower_credential module

* add test coverage for the tower_user module

* fix a bug in py3 for tower_credential when ssh_key_data is specified

* add test coverage for tower_host, tower_label, and tower_project

* add test coverage for tower_inventory and tower_job_template

* add more test coverage for tower modules

- tower_job_launch
- tower_job_list
- tower_job_wait
- tower_job_cancel

* add a check mode/version assertion for tower module integration tests

* add test coverage for the tower_role module

* add test coverage for the tower_group module

* add more integration test edge cases for various tower modules

* give the job_wait module more time before failing

* randomize passwords in the tower_user and tower_group tests
7 years ago
Nathaniel Case 594840c1d6
Close & remove paramiko connection where appropriate (#37528)
* Close & remove paramiko connection where appropriate

* Update unit test
7 years ago
Dag Wieers cdd21e2170
Clean up module documentation (#36909)
* Clean up module documentation

This PR includes:
- Removal of `default: None` (and variations)
- Removal of `required: false`
- Fixing booleans and `type: bool` where required

* Fix remaining (new) validation issues
7 years ago
Matt Clay 58eb2e849d Disable unstable azure_rm_virtualmachine test. 7 years ago
Matt Clay 981e89117a Improve Tower integration test support:
- Add TOWER_VERSION environment variable.
- Add error check for missing configuration.
7 years ago
Martin Krizek a6d31b6fb1
apt: better error msg when update_cache fails (#37410) 7 years ago
Trishna Guha 957ab02e52
Ensure network_cli nxos test is run only once - remove unnecessary files (#37462)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
saichint 05b266cc66 fix nxos_udld issues (#37418) 7 years ago
Matt Clay a8487feb70 Fix ansible-test python and pip executable search. 7 years ago
Trishna Guha dd37857884
fix ios_l2_interface (#37389)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Pilou 4378542ac7 Connection error messages are unsafe: wrap them (#37329)
* Check that connection error msg are not unsafe

* Connection error messages are unsafe: wrap them

For example, in case of error, docker connection plugin returns exception
message containing Go template. These messages weren't tagged as unsafe
and were consequently rendered:

The conditional check 'result is failed' failed. The error was:
{
  'msg': u'Docker version check ([\'/usr/bin/docker\', \'version\', \'--format\', "\'{{.Server.Version}}\'"]) failed: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.35/version: dial unix /var/run/docker.sock: connect: permission denied\n',
  'failed': True
}:
template error while templating string: unexpected '.'.
String: Docker version check (['/usr/bin/docker', 'version', '--format', "'{{.Server.Version}}'"]) failed: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.35/version: dial unix /var/run/docker.sock: connect: permission denied
7 years ago
Matt Clay 30bb70cf2d Disable failing github_issue integration test. 7 years ago
Deepak Agrawal a1026dbce5
Eos :do not push config to device if check_mode is enabled (#37287)
* eos can not check config without config session support

* add testcase for check_mode without config session

* fix eos eapi to read use_session env var
7 years ago
saichint dc61f4c6b1 Fix nxos_vrf issues (#37092)
* fix nxos_vrf issues

* fix doc
7 years ago
Trishna Guha ba5e562c76
Fix nxos_l2_interface and test typo (#37336)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Mike Wiebe ff57fd0bb4 Fix nxos_switchport (#37328) 7 years ago
Julien Vey 099d8f0b56 route53_zone: enable check mode (#37201) 7 years ago
Ganesh Nalawade c1008d693c
Fix eos_facts eapi integration test failures (#37301) 7 years ago
Sebastian Gumprich 16c564c4b4 fix spelling mistakes in several modules (#36296)
* fix more spelling mistakes

* fix spelling mistakes
7 years ago
Matt Clay 11ad559010
Terminate Tower instances after CI ends. (#37265)
* Remove obsolete Tower support from manage_ci.
* Add missing remote settings to cloud tests.
7 years ago
Matt Martz 8980d275a0
Support recursive suboptions schema (#37206)
* Support recursive suboptions schema

* Remove todo line, add voluptuous version constraint
7 years ago
Matt Clay 5688d2243c Update support for Tower testing.
This is required for compatibility with the latest
version of ansible-core-ci, which now handles more
of the Tower instance setup.
7 years ago
mikedlr c2a063a5c0 aws ssm parameter lookup - testing and documentation around negative and failure cases (#36550) 7 years ago
David Newswanger 5e827f4cc4
added nxos_smoke tests (#36647)
* added nxos_smoke tests

* add connection information, check length of output

* updated name of task
7 years ago
Ganesh Nalawade b440544e73
eos_config module exit session gracefully (#37244)
Fixes #36979
If `abort` is not issued in the top level session prompt
the existing session goes to pending state.
The fix is to come out of config mode by issuing `end` command
and again to same config session and execute `abort` which
`abort` is issued at the top level session prompt.
7 years ago
Trishna Guha 2501834c42
add nxos_snapshot test for missing required param (#37248)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Dylan Murray 90943a3362 Add APB role_type to ansible-galaxy init (#36789)
* Add APB role_type to ansible-galaxy init

* Add handlers scaffolding

* Fix shippable errors by setting default

* Add unit tests and fix shippable

* Updates init description
7 years ago
saichint 74e79d9f5e fix nxos_vrf_af issues (#37211) 7 years ago
Abhijeet Kasurde c25a42bef6 VMware: New module : vmware_datastore_cluster (#36365)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Jordan Borean 708869edd6
win: handle non string as an environment value (#37215)
* win: handle non string as an environment value

* Changed powershell environment handler to use .net function instead for special chars
7 years ago
René Moser 0130490faa
cs_instance: fix py3 user_data base64 (#37135)
* cs_instance: tests: reproduce py3 user_data base64 issue

* cs_instance: fix base64 encoding with py3
7 years ago
Trishna Guha 02999b77a4
fix nxos_switchport/l2_interface trunk_vlans state absent (#37180)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Jordan Borean c1f5e11cdf
win_uri: return response info on non 200 responses, convert DateTime values to ISO 8601 (#37104) 7 years ago
Matt Clay b4bf502268 Initial Tower module integration test support. 7 years ago
Matt Clay b9b8081a87
Cleanup and enhancements for ansible-test. (#37142)
* Fix type hint typos.
* Add one-time cloud env setup after delegation.
* Add generate_password to util.
* Add username/password support to HttpClient.
* Avoid pip requirement for ansible-test shell.
* Support provisioning Tower instances.
7 years ago
Julien Vey 7c07877b1b s3_bucket: add integration tests (#36941)
Also update testing-policies/storage
7 years ago
Julien Vey 51d491f8f0 route53_zone: move to boto3, and enable comment update (#36641) 7 years ago
Pilou bc6b96d42e webfaction modules: fix broken import (#35024)
* webfaction_app: fix broken import
* doc: use formatting functions
* webaction_db: fix broken import
* webfaction_domain: fix broken import
* webfaction_mailbox: fix broken import
* webaction_site: fix broken import
* webfaction modules: fix doc
7 years ago
Will Thames a7371d4998 Having uppercase in the resource_prefix can cause unexpected issues
We may as well enforce lower case resource prefixes at source
7 years ago
René Moser e1297af18a cs_router: fix missing doc (#37107)
* cs_router: fix missing doc

* update ignore.txt
7 years ago
René Moser 67d8c8f5c6 cs_ip_address.py: fix missing doc (#37109)
* cs_ip_address.py: fix missing doc

* update ignore.txt
7 years ago
René Moser 2559e832df
cloudstack: fix common E324 in docs (#37082)
Notes about precedence of common args.
Partly fixes E324.
7 years ago
rahushen b7bc61c7df fix nxos_l2_interface tests for fretta (#37086) 7 years ago
Adam Miller 3fd5b0740e allow ANSIBLE_KEEP_REMOTE_FILES for local test runner (#33357)
* allow ANSIBLE_KEEP_REMOTE_FILES for local test runner
* add ANSIBLE_KEEP_REMOTE_FILES to tox.ini, update docs
* Clarify handling of environment variables.
7 years ago
Nathaniel Case efb8b539c1
Don't fail on configure in command (#37011)
* Don't fail on configure in command

* Change test to check mode
7 years ago
René Moser 4705edd1a7
letsencrypt: add new param force (#37077)
* letsencrypt: add new param force to ignore remaining days

* letsencrypt: fix E325
7 years ago
saichint 4ed0e5072d fix nxos_vrrp issues (#36930) 7 years ago
Ganesh Nalawade ba3201cd2f
Fix eos integration test failures (#37020)
Fixes #36919

Fix other eos modules integration test failure in dci
7 years ago
msven a2b3120e85 ec2_asg: fix #28087 and #35993 (#36679)
Fixes #35993 - Changes to update_size in commit eb4cc31 made it so
the group dict passed into update_size was not modified. As a result,
the 'replace' call does not see an updated min_size like it previously
did and doesn't pause to wait for any new instances to spin up. Instead,
it moves straight into terminating old instances. Fix is to add batch_size
to min_size when calling wait_for_new_inst.

Fixes #28087 - Make replace_all_instances and replace_instances behave
exactly the same by setting replace_instances = current list of instances
when replace_all_instances used. Root cause of issue was that without lc_check
terminate_batch will terminate all instances passed to it and after updating
the asg size we were querying the asg again for the list of instances - so terminate batch
saw the list including new ones just spun up.

When creating new asg with replace_all_instances: yes and lc_check: false
the instances that are initially created are then subsequently replaced.
This change makes it so replace only occurs if the asg already existed.

Add integration tests for #28087 and #35993.
7 years ago
Guillaume Coré daeec920b0 ini_file: add allow_no_value param (#24442) 7 years ago
Mikhail Naletov 7d0e1f92f4 [terraform] Support initializing modules and providers at runtime (#36996)
* Fixes #36994

Added function for force initializing modules and providers

Added type for force_init parameter
7 years ago
Nathaniel Case 7016b3b9ca
ios_static_route idempotence fix (#35912)
* Remove default admin_distance and fix the idempotence thereof

Fixes #33290

* Fix tests and use yaml anchors to shorten tests

* Add test for undefined admin_distance

* Read config from `show run` if `show ip static route` fails

* Restore flags to ios.get_config &  use get_config where appropriate
7 years ago
René Moser 6578403288
cs_zone_facts: implement return facts as ansible returns (#36993) 7 years ago
Abhijeet Kasurde d1eb4fe58c
VMware: Refactor vmware_target_canonical_facts (#36964)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Abhijeet Kasurde 3a161fa157
VMware: new module : vmware_datastore_maintenancemode (#36436)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Ganesh Nalawade 83c3561ee5
Enable eapi integration test for eos modules (#36934) 7 years ago
Matt Martz ca092b5c26
Skip top level args that are the same as args in provider in doc<->arg_spec comparisons (#36911) 7 years ago
Ganesh Nalawade 5c2a1a6124
Fix eos_vrf integration test failures (#36893) 7 years ago
Trishna Guha 2fbfce06e7
Fix nxos_interface multiple issues (#36827)
* fix interface_type

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

* fix setting mtu, doc for state check param, doc for params applicable for ethernet intf

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

* speed idempotence and add unittest

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

* fabric_forwarding_anycast_gateway applicable for svi type intf only

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

* fix speed

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Abhijeet Kasurde 0694aca2a0
VMware: refactor configure disk logic (#36617)
This fix corrects logic related to disk parameters.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Pilou 274a4b0688 gitlab_project: don't ignore errors (#36702)
* gitlab_project: check that errors are reported

* gitlab_project: report encountered errors

Fix #36495
7 years ago
Gaurav Rastogi 60e39b9718 Updated the documentation of modules to match argspec including the type setting for bool parameters (#36821) 7 years ago
Claes Nästén 042c111563 nso_config break cycles in dependency sorting (#36828)
False assumption that values can not have cyclic dependencies. Fix by
removing dependency on self and look for cycles, if found remove
dependency to get a partial sort done.
7 years ago
Matt Clay dc71c2197f
More code-smell sanity test updates. (#36830)
* Add test for missing Azure requirements.
* Improve readability.
* Enhance no-unicode-literals code-smell test.
7 years ago
Ed Costello 645952c139 Add aws_caller_facts module and use it in setup-iam.yml (#36683)
* Add aws_caller_facts module and use it in setup-iam.yml

This removes the dependency on having the command line AWS tools
installed.
7 years ago
saichint db43fe6a76 nxos_facts fix and integration tests (#36796)
* fix nxos_facts ipv6 error

* time_range not supported for N35
7 years ago
Abhijeet Kasurde 8d49bb6eee
VMware: new module: vmware_host_capability_facts (#36497)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Matt Clay ac1698099d
Overhaul additional sanity tests. (#36803)
* Remove unnecessary sys.exit calls.
* Add files filtering for code-smell tests.
* Enhance test-constraints code-smell test.
* Simplify compile sanity test.
* Pass paths to importer on stdin.
* Pass paths to yamllinter on stdin.
* Add work-around for unicode path filtering.
* Enhance configure-remoting-ps1 code-smell test.
* Enhance integration-aliases code-smell test.
* Enhance azure-requirements code-smell test.
* Enhance no-illegal-filenames code-smell test.
7 years ago
Claes Nästén e75989ec88 nso_config work around ordering issues (#36774)
Include dependencies when sorting entries to avoid issues with certain
versions of NSO.
7 years ago
Matt Clay 60a24bbdaa Pass code-smell paths on stdin. 7 years ago
Abhijeet Kasurde 87d6bdaf98
VMware: Re-enable VM poweroff testcases (#36734)
This testcases were failing due to vcsim version.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
nwsparks e15a903bdf Win lineinfile fix (#35100)
* win_lineinfile: fix #33858. Removed conversion from \r\n

* win_lineinfile: added test for #33858

* win_lineinfile: added documentation and more tests for change

* win_lineinfile: fixed wrong hash in testing
7 years ago
Matt Clay 009f536d4e Update default docker container SHA.
ci_complete
7 years ago
David Newswanger 6bd715a17d
skip fmg_script unit test if the pyFMG script is not present (#36732)
* skip fmg_script unit test if the pyFMG script is not present

* appease the sanity test gods
7 years ago
Claes Nästén 2789cc5c09 NSO ValueBuilder improvements. 4.5 leaf-list compatability. (#36583)
Fix issues in ValueBuilder used in nso_config and nso_verify so that it
can handle leaf-list in NSO 4.5 and detect identityref types from
unions.

Fail gracefully if a type is not found.
7 years ago
Mário Santos 8b52006d5c Fix sanity checks in OpenStack docs fragment (#36722)
* Fix sanity checks in OpenStack docs fragment

Signed-off-by: Mário Santos <mario.rf.santos@gmail.com>
7 years ago
Peter Sprygada 93b795baf0
allows ib_spec attrs to be filtered in update (#36673)
* allows ib_spec attrs to be filtered in update

This change will allow the ib_spec entries to be be filtered on a change
object by setting the update keyword to false.  The default value for
update is true.  When the update keyword is set to false, the keyed
entry will be removed from the update object before it is sent to the
api endpoint.

fixes #36563

* fix up pep8 issues
7 years ago
René Moser cdb2969703
cs_sshkeypair: fix ssh key rename (#36726)
* tests: cs_sshkeypair: add reproducer for failed key rename

* cs_sshkeypair: fix rename ssh key
7 years ago
Martin Krizek 54e9096950
Add integration test for #36534 (#36581) 7 years ago
Abhijeet Kasurde d94a1ef4cc
VMware: refactor vmware_datastore_facts (#36423)
This fix adds datastore cluster details about datastore in returning
facts. Updated documentation and tests.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Trishna Guha 44332bda78
fix nxos_vlan aggregate (#36710)
* fix nxos_vlan aggregate

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

* Add test

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Ganesh Nalawade 5a6b893240
Decouple config and state check in vlan and vrf network modules (#36386)
* Decouple config and state check in {network_os }_vlan and { network_os }_vrf modules

Fixes #35567
Fixes #34754

`interfaces` option is used for configuration as well as operational state
check. If interface is configured to given vlan or vrf but if
operational state of interface is disabled it results in module failure.

Fix is to decouple same option usage for config and state.
With this fix `interfaces` is used as config option and a new
option named `associated_interfaces` will be used for intent check
for assigned interfaces.

* Fix CI failures

* Fix review comment

* Fixed integration test failure
7 years ago
Matt Clay f283edcb19 Temporarily disable subversion test on osx. 7 years ago
Ed Costello 2a0c7c4331 Fix documentation of validate_certificates option in aws doc_fragment.
Unignore sanity test failures for AWS modules caused by this common
fragment.
7 years ago
Chris Houseknecht 53cfd70b7d
Adds k8s_raw, openshift_raw tests (#36228) 7 years ago
Pilou 07927f52ae filesystem: fix documentation (#36556) 7 years ago
Matt Martz a7062b7587
Start of tests for modify_module, specifically to ensure proper shebang replacement on old style modules (#36602) 7 years ago
Matt Clay 5b5cba5e50
Update more code-smell tests. (#36570)
* Enhance use-compat-six code-smell test.
* Enhance use-argspec-type-path code-smell test.
* Enhance replace-urlopen code-smell test.
* Enhance boilerplate code-smell test.
* Enhance no-underscore-variable code-smell test.
7 years ago
Matt Clay 891f4f3b2d
Upgrade more code-smell tests. (#36560)
* Enhance no-dict-* code-smell tests.
* Enhance no-basestring code-smell test.
* Enhance no-get-exception code-smell test.
* Enhance empty-init code-smell test.
* Enhance required-and-default-attribute test.
* Remove unused code-smell test.
7 years ago
Jordan Borean ef4f8851dc
win_feature: better error handling to make it easier to debug issues (#36491)
* win_feature: better error handling to make it easier to debug issues

* removed ignroed pslint rules that are no longer needed
7 years ago
Dag Wieers 430088c6f0
aci_interface_policy_leaf_policy_group: Fix test (#36551) 7 years ago
Sam Doran 723daf3e3a
Check for regexp match when using insertbefore or insertafter (#36474)
Add tests to cover this scenario
Fixes #36156
7 years ago
Bruno afdd748f4c changed cisco mail to normail hotmail (#36546) 7 years ago
Bruno 53125d37d1 add aci_static_binding_to_epg integration tests (#36542) 7 years ago
Dag Wieers 51ba115dea
aci_domain_to_encap_pool: Remove integration tests (#36535) 7 years ago
Toshio Kuratomi 03a6d72633 Revert "remove query/q (#36315)"
This reverts commit b47d2e07e1.

query is a feature for 2.5.  We're not reverting it now.
7 years ago
Dag Wieers 7435e115e0
ACI: Various changes to module documentation and guide (#36516)
* ACI: Various changes to module documentation and guide

This PR includes:
- We moved the object class information to the notes
- Add version information to guide chapters
- Add generic note to modules with reference to ACI guide
- Reference known issues in aci_rest documentation
- Remove module_utils function docs from modules
- Indicate which parameters are not required for querying all objects
- Added missing RETURN information

* Fix copyright strings

* Remove aci_domain_to_encap_pool.py for v2.5

* More updates

* PEP8 fix

* Improve listings of parameters/return values
7 years ago
Brian Coca b47d2e07e1
remove query/q (#36315)
* remove query/q

remove and fixed tests for removed func

* paren fix
7 years ago
John R Barker 5d0ed38e3a
Fixup VMware module docs issues (#36409)
Fix various argspec vs documentation issue
7 years ago
Martin Krizek 9fced4f0a9
Add integration test for #36430 (#36432) 7 years ago
Sloane Hertel f7d79d4789 [cloud] Retry WAF actions on WAFStaleDataException (#36405)
Add a util to run functions with AWSRetry to retry on WAFStaleDataExceptions and update ChangeToken for each attempt
7 years ago
mikedlr 52f2057472 aws ssm parameter lookup - change to return Nones for missing variables (#36456)
* aws ssm parameter lookup - change to return Nones for missing variables

* aws ssm parameter lookup - fix error case message to dump response

* aws ssm parameter lookup - fix integration test cases
7 years ago
Jordan Borean df8a5d7a4f
fetch: set fail_on_missing: True as default as per docs (#36469)
* fetch: set fail_on_missing: True as default as per docs

* Updated docs for fetch to say behaviour was changed in 2.5 and updated tests
7 years ago
goshkis abb956d9eb vApp properties support (#32579)
* Adding support for vApp properties.
* vm specification updated only if changes have to be applied. I.e. subsequent updates with the same data will not trigger changed state
* Auxiliary variables renamed, hope this makes the code more readable
* Integration tests changed - re-adding the same properties test not implemented, but tested on real vCenter deployment
* fixing documentation "version_added" for the feature
* Addressing reviewers comments #2:
* documentation updated with the only meaningful value for "option" attribute - "remove"
* Fixed improperly handled case when user requested "add" operation for existent property
* vApp configuration is updated only with properties that contains changes, not with all properties requested by user
7 years ago
saichint 47a92386c9 fix nxos_bgp_neighbor_af issues (#36472) 7 years ago
Dag Wieers 5635c50f9b
aci_iplpg: Various fixes to integration tests/module (#36460) 7 years ago
Dag Wieers 1720a210e9
aci_spvpg: Various fixes to integration tests/modules (#36458)
* aci_spvpg: Various fixes to integration tests/modules

This PR includes:
- A fix in module_utils aci.py
- Various fixes in integration tests

* Fix typo
7 years ago
Matt Clay 2b6ac4561b
Add support for enhanced code-smell tests. (#36332)
* Add support for enhanced code-smell tests:

- Path selection handled by ansible-test.
- Optional path filtering based on extension.
- Optional path filtering based on prefixes.
- Optional lint friendly output.

* Enhance no-assert code-smell test.
* Enhance no-tests-as-filters code-smell test.
7 years ago
Bruno 7143cf54bc added aci_vpc_protection_group integration test (#36448)
added aci_switch_policy_vpc_protection_group integration test
7 years ago
Matt Clay a9b58b84d8 Fix path handling in validate-modules sanity test. 7 years ago
Trishna Guha 3d06ce245a
fix vyos_l3_interface adding multiple addresses to interface (#36377)
* fix vyos_l3_interface adding multiple addresses to interface

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

* add test

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Bruno 4a6d837879 added aci_fabric_node integration test (#36422)
* added aci_fabric_node integration test

* Update main.yml
7 years ago
Brian Coca a79378fccb remove extra fields from debug output
fixes #35493

updated tests
7 years ago
Deepak Agrawal 0bbea9a579
vyos_config IndexError in sanitize_config (#36375)
* Bug in del(list) logic. Say you have a list of 4 elements a[0-3]
and you have to remove index 1 and 3, if you remove index 1 first
then list is cut short a[0-2] and does not have index 3

Fix: Remove indexes in reverse sorted order e.g. 3 and 1 in above
example so that order of indexes remain preserved even after deleting

fix is to remove indexes in reverse sorted order

* Add test cases for failed case
7 years ago
Jiri Tyr 000387ac23 Fix default value of gpgcheck in doc (PR #36267) 7 years ago
Matt Clay 78e900cd7f Fix ansible-test --redact option with delegation. 7 years ago
saichint 80d19e6af3 fix nxos_bgp_neighbor issues (#36318) 7 years ago
Dag Wieers cac6c19a63
aci_encap_pool: Fix vxlan integration tests (#36418)
Missing cleanup would cause subsequent runs to fail when interrupted.
7 years ago
Dag Wieers 6534e6a450
ACI: Add missing examples to module docs (#36417)
This PR includes:
- A cleanup of documentation examples for ACI modules
- A small fix in aci_rest integration test
7 years ago
Dag Wieers fb9af72b48
aci_aep: Add missing integration tests (#36414)
This PR includes:
- Add missing aci_aep integration tests
- Fix small aci_rest issue
7 years ago
Matt Clay 3a62eb5e03 Add option to hide sensitive ansible-test output.
This option is enabled automatically on Shippable.
7 years ago
Matt Clay 5bc9bb9fbb Support ansible-test --truncate with delegation. 7 years ago
Dag Wieers 32dc936c20
aci_rest: Remove test data from validation test (#36381)
Oops
7 years ago
Dag Wieers 79d00adc52
aci_rest: Fix error handling and improve documentation (#36295)
This PR includes:
- A fix for a recently introduced issue wrt. error handling
- Added integration tests for provoked errors
- Influence standard return values using aci library for aci_rest
- Add proxy support documentation
- Documentation update related to #34175
7 years ago
Trishna Guha eb7f4460c8
Set hostname to 'switch' on nxos_system (#36373)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Trishna Guha a5654bd63c
nxos_system test fix inventory_hostname_short (#36359)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
ABond 591695932e Fix bug in DigitalOcean module_util (#36352) 7 years ago
Abhijeet Kasurde 5242914ae5
Fix digital ocean issues (#36347)
Remove module from ignore lists and some documentation fix in
digital_ocean_block_storage and digital_ocean module.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
rahushen e24c547a3a Fixes for the N3500 platform that uses the A8 image (#36261)
* fix nxos_l3_interface tests as n35 doesn't support ipv6

* add terminal dont-ask to nxos_feature and nxos_lldp

* put interfaces in L2 mode for N35

* fix nxos_feature unit-tests
7 years ago
Mike Wiebe 5b5d24631a Fix nxos_system tests (#36201)
* Fix nxos_system tests

* Add debug connection plugin info

* Move sanity test under common
7 years ago
Matt Clay ff922ac2ad Import sanity test for main() in Ansible modules. 7 years ago
John R Barker 365630df65
Update ignore to deal with renamed files (#36323) 7 years ago
Martin Krizek 3a5263a92f facts: fix device uuid's on el6 (#36128)
* facts: fix device uuid's on el6

Fixes #36077
7 years ago
David Newswanger a7c2f6d092
re enabled tests that were fixed in ansible/ansible-modules-core#5008 (#36257) 7 years ago
Matt Clay d2150795ba Truncate some long messages sent to a TTY.
Can be overridden with the --truncate option.
7 years ago
Matt Clay 80b55e3742 Add missing validate-modules ignore entries. 7 years ago
Dag Wieers d86c5aee3c aci_domain_to_encap_pool: Add integration tests (#36217) 7 years ago
Abhijeet Kasurde 3ecf2d5ba2
VMware: New module: vmware_guest_snapshot_facts (#36002)
This module gathers facts about VM's snapshots.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Abhijeet Kasurde 55d117458a
VMware: New module: vmware_guest_disk_facts (#36026)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Abhijeet Kasurde a377302d6b
VMware: Fix DVPG idempotency issue (#35837)
This fixes, cloning operation where template or existing VM
does not have network or DVPG. Also, adds some strict type checking in
network parameters.

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
saichint 75a34f6668 fix nxos_bgp_af issues (#36147)
* fix nxos_bgp_af issues

* shippable fix

* review comments

* shippable error fix
7 years ago
Dag Wieers 334e405e6f
aci_taboo_contract: Add integration tests and examples (#36276)
This PR includes:
- Missing integration tests
- Missing examples
- Two typo's in other integration tests
7 years ago
Dag Wieers e1b5bc049c
aci_firmware_source: Add integration tests (#36246)
This PR includes:
- Rename 'protocol' parameter to 'url_protocol'
- Add limited integration tests (as we have no public firmware access)
- Add missing examples
7 years ago
Matt Martz 831a9d67d7 Arg spec doc comparison fixes (#36265)
* Ensure we merge doc fragments early, for comparisons

* Perform boolean conversion from arg_spec data too

* Update valdiate-modules ignore.txt due to recent changes
7 years ago
Matt Martz 50adc5409b Add several new doc<->arg_spec checks (#36247)
* Add several new doc<->arg_spec checks. See #18183

* Update ignore.txt for validate-modules
7 years ago
Tim Rupp 77fa41795e Reduces the unit test time of select bigip modules (#36256)
The modules in this patch include waits that need to happen to ensure
something is correctly configured on a BIG-IP. These waits were
raised as an issue in a recent ansible-testing meeting.

This patch eliminates the waits by mocking time.sleep
7 years ago
Toshio Kuratomi 06f73ad578
Normalize usage of temp and tmp on tmp (#36221)
* Normalize usage of temp and tmp on tmp
* Rename system_tmps system_tmpdirs
* Add ANSIBLE_REMOTE_TMP spelling of environment variables
7 years ago
Monty Taylor 0f893027c4 Add a module_utils OpenStack Cloud constructor (#20974)
Start using this to construct shade OpenStack Cloud objects in a
consistent manner. This will let us centralize things like dealing with
password arguments and whatnot. It also allows us to introduce the
ability to pass a fully formed config dict directly to the module.

Migrate all OpenStack modules to use openstack_cloud_from_module.

Have it return the shade library since it's responsible for
importing shade and shade is needed for the exceptions.

Only pull specific OpenStack arguments for the constructor

Rather than passing **module.params to the shade constructor, pull out
only the values that make sense. This should prevent the issues with
module parameters stepping on shade parameters.

Replace module.params.pop with module.params.get

We don't need to pop these anymore since the shade constructor is now
using opt-in values.

Using real urls is ungood. Use example.com domains. Also, get rid of the
antiquated port numbers.
7 years ago
Mike Wiebe 787114462e Fix nxos_linkagg tests (#36175) 7 years ago
Dag Wieers e431d578da
aci_encap_pool: Standardize on 'pool_allocation_mode' (#36215) 7 years ago
David Newswanger 3f5caf659e added support for --testcase flag in ansible-test (#36134)
* added support for --testcase flag in ansible-test

* fixed command format

* added tab completion

* fixed sanity issues

* added documenation for --testcase

* don't autocomplete when multiple modules are selected
7 years ago
Dag Wieers dba561efa7
ACI: Avoid using 'previous' with query operations (#36181)
When ACI modules are being used for querying MOs, we should not return
the previous state, as there is no previous state, there's only the
current state.

This impacts a lot of tests that were used to testing the current state
as 'previous'.
7 years ago
Brian Coca 0cf70a8970
never tags docs and test (#35964)
* fufilling the promise

* moved changes

* Copy edit
7 years ago
Matt Clay 032dc1a7c5
Initial OpenShift integration test support. (#36207)
Based on integration tests from chouseknecht for openshift_raw.
7 years ago
Jordan Borean f8d1c97279
win_uri: fix creates/removes option (#36016) 7 years ago
Matt Clay 6a4f6a6490 Add additional support code in ansible-test. 7 years ago
Jordan Borean 8fb66c18de
win_updates: fix regression when using string cat names (#36015) 7 years ago
John R Barker 7dfa11cd8a Notice in 2.6 remove in Ansible 2.10 (#36191)
Update the list of allowed removed_in for modules
7 years ago
Dag Wieers 3093285c94
aci_vlan_pool: Improve integration tests (#36173)
This PR includes:
- More elaborate integration tests
- Split static and dynamic VLAN pools in separate files
7 years ago
John R Barker 3e22efa0ba
Ensure docs are valid before checking deprecation (#36160) 7 years ago
Sam Doran 97573d8b0c
Add unit tests for edgeos_command (#35861) 7 years ago
Dag Wieers da5cf72236
ACI: Fixes to domain parameters dependencies (#36158)
We identified an incompleteness to parameter dependencies that affects
querying all domain-related objects.

This PR also includes:
- Improvements to integration tests
- Add missing vm_provider types
- Fix examples

This relates to #36131
7 years ago
Dag Wieers 7897558b95
aci_aep_to_domain: Fix query all objects (#36131)
This PR includes:
- A fix to the module where domain_type without domain caused havoc
- A fix to the integration tests when querying all binding objects
- Improvements to integration tests
7 years ago
David Newswanger 01bd9759e3
[WIP] Add ios smoke tests (#35972)
* added basic ios_smoke files

* added smoke tests for network.common.config

* added tests for network.common.utils

* added remainder of test cases
7 years ago
Brian Coca 8743b20c8e skip aws inventory test if no boto 7 years ago
Abhijeet Kasurde 66743f33fa
VMware: re-enable vmware_guest_powerstate tests (#36092)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
saichint eab1b62cd2 fix nxos_interface_ospf issues (#35988)
* fix nxos_interface_ospf issues

* review comment
7 years ago
Matt Clay 1f80361bf9 Restore azure_rm_sqlserver test in CI. 7 years ago
Dag Wieers 9f028e9dea
aci_domain_to_vlan_pool: Add missing integration tests (#36079) 7 years ago
Dag Wieers 98a3059f7b
aci_aep_to_domain: Add missing integration tests (#36071) 7 years ago
Dag Wieers 30adc2f124
aci_domain: Add missing integration tests (#36051) 7 years ago
John R Barker 17c0d3eae0
Fix more docs vs argspec (#36048) 7 years ago
Stefan Horning 404f9260d9 [cloud][aws] Add metrics_collection options to ec2_asg module (#35180)
* Added metrics_collection management to ec2_asg module to switch ASG metrics on and off.

* Fixed typo in documentation of ec2_asg module

* Removed extra blank line in ec2_asg.py

* Docs fixes for ec2_asg module

* Added integration test for ec2_asg metrics flag

* Trying different syntax for ec2_asg test
7 years ago
Ganesh Nalawade 6a223d5576
Fix vrf parsing in eos_vrf and eos_eapi module (#35791)
* Fix vrf parsing in eos_vrf and eos_eapi module

Fixes #30250

Fix logic to parse vrf when interface value in `show vrf`
command output spans on multiple lines

* Add idempotent test case
7 years ago
Nathaniel Case 6cdf91fd35
Fix VyOS check mode (#35977)
* Revert "commented out check tests (#35788)"

This reverts commit 3df2561405.

* `discard_changes()` now uses `exit discard`

instead of just `discard`. Also a slight tweak to avoid a second `exit` after
`exit discard`
7 years ago
Matt Clay a9a7d15698 Disable unstable Azure integration tests. 7 years ago
Matt Clay e7b793c8c6
Move requirements into tests. (#35885) 7 years ago
Matt Clay 1d0fd49a33 Rebalance cloud tests into 5 groups. 7 years ago
Matt Clay 25ca0863c1 Disable unstable azure_rm_containerinstance test. 7 years ago
Matt Clay 1d419c737d Run each Windows version independently in CI. 7 years ago
Matt Davis 26f551d1c3
initial cutover to API profiles (#35538)
* hardcoded API profiles in azure_rm_common
* changed azure_rm_securitygroup module to use api_profiles, dynamic models, kwargs on all SDK methods
* changed azure_rm_containerinstance module to use api_profiles, dynamic models, kwargs on all SDK methods
* fixed polling performance issue in azure_rm_securitygroup (default poll interval was 30s)
7 years ago
Dag Wieers 01ba3a4efc
ACI: Fixes to recent change to parameter choices (#35968)
This PR includes:
- Fixes related to the recent merge of #31637 and #34537
- A generic fix for a reference for assignment issue
- Fixes to aci.boolean() in order to catch exception
7 years ago
Dag Wieers d76db835ff
aci_interface_policy_leaf_policy_group: Fix tests (#35973) 7 years ago
Ryan Brown f4d896c716 Tower callback fixes (#35927)
* Fix tower_callback script return code

* Add ec2_key parameter to integration tests
7 years ago
saichint c7305393a3 fix nxos_evpn_vni issues (#35930) 7 years ago
Tomasz Kontusz d73c3abb15 Copy tests: check the result of non-changing copy 7 years ago
Matt Clay 14f6b4d766 Remove extra NuGet files from the default image. 7 years ago
Toshio Kuratomi 03c73e2bbb Rename var lookup to vars and add tests 7 years ago
Toshio Kuratomi abbac1a2ff Revert "Temporarily comment out tests causing CI errors (#35883)"
This reverts commit 157a41c843.

Have a fix for the underlying issue so reenabling the tests
7 years ago
Toshio Kuratomi d4b31afbc5 Test that transient failure in the middle of running async_status doesn't fail the task 7 years ago
saichint 80fcfdc0d1 fix nxos_vpc issues (#35868) 7 years ago
Felix Fontein d1f19125a5 openssl_csr: added support for the OCSP Must Staple extension (#35082)
* Added support for the OCSP Must Staple extension.

* Trying to clean up magic constants a bit.
7 years ago
Yuwei Zhou 273a3d1d51 Fixes #34913: azure_rm_loadbalance should accpet a list of rules instead of one (#35592)
* azure_rm_loadbalance should accpet a list of rules instead of one

* fix lint

* fix

* fix

* hook up load balancer rules, doc fixes, test updates
7 years ago
Toshio Kuratomi 8a22b51755
Fix copy for implicit relative paths (#35016)
copy currently fails if you specify a destination without any directory
component.  This is because we take the dirname of the destination for
some processing and no dirname causes issues.

This corrects that by prepending "./" if there is no directory component
in dest.
7 years ago
Matt Clay 2a0adaf542 Improve bot messaging on CI failures. 7 years ago
Matt Clay 95f202a7e3 Disable hg test on Python 3 again. 7 years ago
René Moser 2f36b9e5ce basic: allow one or more when param list having choices (#34537)
* basic: allow one or more when param list having choices

* add unit tests

* optimize a bit

* re-add get_exception import

* a number of existing modules expect to be able to get it from basic.py
7 years ago
Ryan Brown e71c6d8e17 New module: ec2_instance (#35749)
New module: ec2_instance

Integration tests for ec2_instance
7 years ago
James Mighion 663c410da4 Fixing eos_config save option. Was removed when deprecated. Fixing ot… (#35628)
* Fixing eos_config save option. Was removed when deprecated. Fixing other deprecation documentation. Adding unit tests.

* Fixing removed_in_version for force.
7 years ago
Matt Clay 75a285ded9
Enable hg test on Python 3. (#35884)
* Enable hg test on Python 3.
* Install/uninstall mercurial during test as needed.
7 years ago
Sloane Hertel 157a41c843
Temporarily comment out tests causing CI errors (#35883) 7 years ago
Sam Doran 6037e73c16
Add EdgeOS config module (#35867)
* Add edgeos_config module

* Add edgeos_config module

* Remove debugging statements

* Add future import and correct module name in docs
7 years ago
Sam Doran a9da1c2927
Add EdgeOS facts module (#35871)
* Add edgeos_facts module and unit tests

* Add future import
7 years ago
Maarten Bezemer 7225839bef [git] Fix switching branch of shallow clone (#18728)
* [git] Fix fetching branch of shallow clone

* Use absolute file:// paths to make sure git uses shallow clones

* Improve tests

* Fix sanity errors
* Match style according to other (depth) tests

* Improve tests

Now they will fail without the fix of this PR
7 years ago
Sloane Hertel 45ef6bdd40
Roll boto3_conn tests into ec2_asg (#35854)
* Roll boto3_conn tests into ec2_asg.
7 years ago
Chad Norgan 9bbf97632c [WIP] Add new network module for EdgeOS (#33109)
* Add edgeos network module using network_cli

* Add documentation and some sanity test fixes

* Update copyright and documentation
7 years ago
Rob 9451212855 [cloud] New AWS module - elb_target (#26483)
* New module - elb_target

* Work to add deregister functionality

* Add jurajseffer work on waiting for status change

* List the set of statuses as a choices list

* default target_status_timeout is 60

* Add 'unavailable' as a target status choice per API docs

* Add support to remove targets that are in unused state

* add support for availability zone selection

Fix deregistering targets from used target groups

Fix waiting for unused state for targets that have started deregistering
7 years ago
Will Thames fcd09e2f02 New aws_waf_web_acl module (#33212)
* Add aws_waf_web_acl rule

* Add new aws_waf_web_acl to CHANGELOG
7 years ago
Jordan Borean a0178b79f1
win_uri: fixes (#35487)
* win_uri: moved away from Invoke-WebRequest and fixed multiple issues

* fixes from review
7 years ago
Martin Krizek 63fdc3f08f
Fix jinja2>=2.9 nested include vars (#35099)
This fixes a bug when parent's local vars where not available in nested
includes. The bug can only be seen with jinja>=2.9 which changes
how the variable scopes work.

Fixes #34886
7 years ago
Trishna Guha a8e14a35de
always remove interface after testing (#35822)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Ian Philpot e62c1cd050 Az mod keyvault ops (#33606)
* keyvault_operations module init + template

* Created KeyVault Secrets Module. No Tests

* Passing 2.7/3.x sanity tests

* added intergration tests for keyvault secrets noop

* integration test pass/need keyvault module

* Added az env cleanup to intergration tests

* Updated auth to 0.3.6 ver

* fixed typo in integration tests

* Added check_mode

* Added tags

* Updated tags test, sanity + integration passed

* checked mode

* updated tests

* fixing sanity

* fix copyright
7 years ago
Ian Philpot 11382fac7a Az mod keyvault key (#33607)
* key module init

* Create/Delete pass sanity

* Integration tests passed

* Added check_mode

* Updated to support tags

* updated key tests

* fixed sanity

* added things that went missing during rebase

* fixed sanity

* fixed doc

* fix copyright
7 years ago
saichint c9e0ce1d7d fix nxos_vpc_interface peer_link idempotence (#35737)
* fix peer_link idempotence

* review comment
7 years ago
Pilou 54882d4715 dimensiondata: fix broken import (#35634)
* Fix broken import

* Remove never reached statements

exit_json and fail_json methods call sys.exit, subsequent statements
can not be executed.
7 years ago
Toshio Kuratomi 86242e6871
Enable wildcard import pylint (#35786)
* Wildcard imports should be taken care of.  Enable the pylint check for them
* Remove wildcard import code-smell test as we're now checking via pylint
* Add unused-wildcard-import as ignored in our compat code.

These three files use wildcard imports so that they can export
symbols in a compatible location.  The real code lives elsewhere.
So disable the pylint tests for the relevant sections of code.
7 years ago
mikedlr d31ded47fb Aws ssm multiple fixes (#35569)
* aws ssm parameter lookup test case - fails demonstrating no exception when parameter missing

* aws ssm parameter lookup - fail in case parameter doesn't exist

* aws ssm parameter lookup test case - failing case for nice return from path lookup

* aws ssm parameter lookup - convert incoming taglist to a key-value dictionary

* aws ssm parameter lookup - pep8 / style clean up

* aws_ssm lookup plugin rewrite for more standard interface

* aws_ssm module and lookup - introduce integration test and fix:

* aws_ssm module and lookup - error case integraton test and many PEP8 and other cleanups

* aws ssm parameter lookup - Various fixes in response to review + recursive fix & test

* aws ssm parameter lookup - more in response to review - shertel/abadger

* aws ssm parameter lookup unit test - move to mocker according to abadger

* aws ssm parameter lookup - integrate with new documentation fragment

* aws ssm parameter lookup - accept either aws_profile or boto_profile

* aws ssm parameter lookup - eliminate lookup document fragment until env vars are fixed later
7 years ago
Matt Clay f46f6c8dec
Temp install of setuptools for import coverage. (#35752) 7 years ago
George Nikolopoulos b1a8f3b3d3 Netscaler various fixes (#34800)
* Add default lb vserver option in netscaler_cs_vserver
Add documentation for ssl_certkey option in netscaler_cs_vserver

* Add options for gracefully disabling netscaler_server

* Add "state" suboption for netscaler_servicegroup servicemembers
Fix servicemember modification algorithm in netscaler_servicegroup
Fix monitorbindings modification algorithm in netscaler_servicegroup
7 years ago
David Newswanger 3df2561405
commented out check tests (#35788) 7 years ago
Alex Stephen 9706abf685 [cloud] New GCP module: DNS Managed Zones (gcp_dns_managed_zone.py) (#35014) 7 years ago
Toshio Kuratomi a5b80464df Fix packaging/os modules for wildcard imports and get_exception 7 years ago
Abhijeet Kasurde 1119709b56 Remove get_exception from modules
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Bruno 5278948e63 adding aci_interface_policy_leaf_policy_group integration tests (#35486)
* adding aci_interface_policy_leaf_policy_group integration tests

* Added more ACI options for testing
7 years ago
Kai f30a08d049 Add vfat support for the filesystem module (#23527)
* Add fat filesystem support

fatresize is temporarily disabled

* Refactor Filesystem.get_dev_size

For more sharing with vFAT class

* Fix filesystem tests on some OSs

I think this is due to older mke2fs on those systems.

* Fix vFAT command on FreeBSD

newfs doesn't seem to work on image files

* Refactor filesystem.grow()

Split out grow_cmd generation and Device operations

* Use swap as unsupported filesystem

Except FreeBSD, which doesn't have mkswap

* Be consistent about str(dev) vs dev.path

Prefer str(dev), this works transparently with '%s' formatting.

* Enable vfat resize, only test fatresize >= 1.0.4

Lower versions have a segfault bug.

* Only install fatresize where available

FreeBSD, OpenSUSE, RHEL and CentOS < 7 don't ship it.
7 years ago
Artem Zinenko 56f640d874 influxdb_user: implement user password change (#35471)
* Added tests on user removing

* Implemented password changing

* Fix after review

* Added zhhuta changes
7 years ago
Mike Wiebe 358e63232f Minor updates to nxos_nxapi tests (#35750)
* Minor updates to nxos_nxapi tests

* Fixed duplicate yaml key issue

* Make rubocop happy
7 years ago
Andrew Gaffney e9b0a4ccb4 Add support for defining index var for task loops 7 years ago
Abhijeet Kasurde 635036fb62
VMware: Add new module : vmware_host_firewall_manager (#35596)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Zim Kalinowski 86c62e228d [new module] azure_rm_keyvault (#35150)
* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* updates to azure_rm_keyvault

* fix update bugs, add update test
7 years ago
Ken Evensen 5cce0249f3 Fixes #35629 (#35668) 7 years ago
René Moser 24b8f36f1e
exo_dns_record: remove limitation for multiple records only for A type (#35173) 7 years ago
Abhijeet Kasurde c33b02f71a
VMware: add new module vmware_vmkernel_facts (#35535)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Abhijeet Kasurde e9e8151c6d
VMware: add new module vmware_host_dns_facts (#35708)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Matt Martz e3b6b40d88
Match recent Dockerfile change in httptester playbook file, to extend ca cert lifetime (#35734) 7 years ago
Abhijeet Kasurde defff8ceb4
VMware: add new module : vcenter_folder (#35608)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Abhijeet Kasurde 8428f13bc1
VMware: add new module vmware_host_firewall_facts (#35467)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Matt Clay df3265a811 Extend httptester CA cert lifetime. 7 years ago
Mike Wiebe 0de810fdf7 Fix nxos_bgp tests and prepare_nxos_tests refactor (#35694) 7 years ago
saichint 109bc89bbe fix nxos_ospf_vrf issues (#35616) 7 years ago
René Moser 588cd749ac
cs_network: implement support acl (#35706) 7 years ago
Abhijeet Kasurde 367258507a
VMware: Provide verbose message about non-existent VM (#35682)
This fix adds a verbose message about non-existent VM when specified
with operation, due to idempotency we can not detect correct state.

Fixes: #27384

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
René Moser c6f397b160
cs_vpc: fix network_domain param ignored (#35690) 7 years ago
Mike Wiebe 5a198e1e6a Add minor conditional checks to nxos_bgp sanity test (#35476)
* Add minor conditional checks to nxos_bgp sanity test

* Make ansibot happy
7 years ago
Dag Wieers bee765fa6b
ACI: Change RETURN output as discussed (#35617)
* ACI: Change result output as discussed

* Update all modules to use new aci.exit_json()

* Update output_level spec and docs

* Fix integration tests

* Small PEP8 fix

* Asorted fixes to tests and aci_rest

* More test fixes and support for ANSIBLE_DEBUG

* Fix another PEP8 issues

* Move response handling inside ACI module

* Reform of ACI error handling and error output

* Diff multiline json output

* Fix a few more tests

* Revert aci_bd tests

* Small correction

* UI change: existing->current, original->previous

* UI change: config->sent

* Update all modules with RETURN values

* Fix a few more tests

* Improve docstring and add 'raw' return value

* Fix thinko

* Fix sanity/pep8 issues

* Rewrite unit tests to comply with new design
7 years ago
Matt Clay 685dd5e8b4 Disable failing aws_waf_web_acl tests. 7 years ago
Will Thames 4e30eff651 [cloud][aws] New module: aws_waf_rule module (#33124)
Add a new module for managing AWS WAF rules

Preceded by aws_waf_condition and to be succeeded by aws_waf_web_acl
7 years ago
David Newswanger 69cd705634
Add vyos smoke integration tests. (#35456)
* added preliminary vyos smoke tests

* added comments, determined current tests are sufficient

* add tests for check mode in module_utils.network.vyos

* removed vyos_smoke from shippable

* added comment explaining why AWS/Shippable tests won't work
7 years ago
Sloane Hertel 7917e3c988
Fix syntax error so route table tests always try to clean up (#35663)
* Always try to clean up after route table tests

* Wait for a new VPC a chance to become available before attempting to get its current state
7 years ago
Pierre-Louis Bonicoli 2646ea9b86 yum_repository: Python 3.7 error have been fixed
See 232dc7110c
7 years ago
Pilou d608eb9530 Check that AnsibleUndefinedVariable doesn't occur when an unused variable references an undefined variable (#35571)
* Check that AnsibleUndefinedVariable doesn't occur

* AnsibleUndefinedVariable exc.: don't modify type
7 years ago
Martin Krizek c3199dca6c
Add any_errors_fatal in nested failed block test (#35499) 7 years ago
Nathaniel Case f3337e1fba
ios test changes (#35510)
* Fix over-byte

* Update ios tests to call `provider`

To continue to support testing `connection: local`

* Fix command dict handling in ios_user

* Clean up unit tests, too
7 years ago
Trishna Guha dc4a41a4af change testfiles for nxos_file_copy (#35641)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
James Mighion f04d40640e Fixing name from aruba to ios. (#35630) 7 years ago
Will Thames b5a1643e3d Add new aws_waf_condition module (#33110) 7 years ago
Sam Doran f8f2b6d61d
Fix lineinfile to insert line when pattern exists elsewhere in the file. (#33393)
* Insert lines before or after when the regexp exists elsewhere in the file

* Correct filter syntax in lineinfile integration test

* Use multi-line YAML syntax on lineinfile tests

Unify indentation

* Add lineinfile tests for same line matched to different regexps

* Remove debug statement from test
7 years ago
Toshio Kuratomi 4a48fdba1d
Update code smell blacklists (#35621)
Update blacklist for get_exception, boilerplate, and no-wildcard.

f5, lenovo, and junos have updated their code.
7 years ago
Artem Zinenko b9571eb4bf Integration tests for rabbitmq_user module (#35421) 7 years ago
Matt Clay b9c5147be2
Move import sanity test files into own directory. (#35593) 7 years ago
Kedar Kekan 684e953b50 * adds commit replace with config file for iosxr (#35564)
* * adds commit replace with config file for iosxr
* fixes dci failure in iosxr_logging

* * review comment changes
7 years ago
Matt Clay ea70b49b11 Fix pip integration test. 7 years ago
Zim Kalinowski fef684d457 fixing mysql and postgresql test failures (#35587) 7 years ago
Dag Wieers 12b8b8dcf2
aci_aaa_user: Manage AAA users on ACI fabrics (#35543)
* aci_aaa_user: Manage AAA users on ACI fabrics

* Fix module documentation

* Ensure we allow to not set accountStatus and expires

* Added aaa_password_lifetime and aaa_password_update_required support

* Improvements to integration tests in light of issue 35544

* Fix ACI ISO 8601 formatted string

* Add HAS_DATEUTIL
7 years ago
Toshio Kuratomi e8cfe05e37 Test behaviour of loop keyword plus lookup plugins
We introduced the new loop keyword as a replacement for with without
adding tests that it behaved as we expected.  This test asserts that
behaviour.

Incidentally, it also shows how to use parameters with lookups and loops
now.
7 years ago
Alicia Cozine adf76b7d3f
Reflect new process for network integration tests (#35577)
With `ansible-test network-integration` we don't need the top level yaml files
except NXOS and Dell (for now)
7 years ago
Sloane Hertel 556bb7ab00 [cloud] Log more exception info to fix sts_assume_role integration tests (#35570) 7 years ago
John R Barker 9728857e01
Remove network-test-runner (#35556)
Not been used for a while, replaced by DCI
7 years ago
Matt Clay 2d565d14ed Add pslint sanity test settings.
Globally ignore rule: PSUseShouldProcessForStateChangingFunctions
7 years ago
kiorky 9001a8794f FIX: multiple nested tasks include levels (#35165)
* Test for include_tasks & include_role bug

Related to ansible/ansible:#21890

* Fix nested include_tasks called from role

This fixes the path of included files when you want
to call include_task inside a role's task file and this
role is itself called from multiple level of playbook include_tasks

Related to ansible/ansible:#21890
This fixes ansible/ansible:#35109
7 years ago
Kim Blomqvist 63639abb01 [cloud] Improve ipv6 and EC2 classic support in ec2_group integration tests (#32976)
* ec2_group: fix ipv6 tests to use an explicit VPC

* otherwise would fail on old AWS accounts supporting EC2-classic

* ec2_group: fix tests to use an explicit VPC

* Only run some tests if there is a default vpc associated with the account
7 years ago
saichint dc35baa8db fix nxos_pim_interface issues (#35405)
* fix nxos_pim_interface issues

* add absent test for pim_interface
7 years ago
Jordan Borean 62b87bc925
change .encode to to_bytes (#35522)
ignore backup dir in test integration targets folder
7 years ago
Clement Trebuchet 287f3a609e Fixes #35468: ADD max_results to the nios api (#35473)
* Fixes #35468: ADD max_results to the nios api

* Fixes #35468: fix nios unittest

* Fixes #35468: document the module docs fragments for nios
7 years ago
Matt Martz c282e4e00f
Replace LooseVersion comparison with int/float comparison. Fixes #35435 (#35519) 7 years ago
Harri Tuominen 234a877ea5 Netact cm command2 (#34873) 7 years ago
Matt Martz f659cc5963
Guard against assignments that are not ast.Name in docs parsing (#35513) 7 years ago
Ganesh Nalawade ef34eb1a7d
Fix junos integration test failures (#35508)
* More integration testcase fixes for junos_facts
7 years ago
Adam Miller 6cc5e4c9df
galaxy remove incorrect check for role path before extraction (#35259)
* galaxy remove incorrect check for role path before extraction

Fixes #35217

Currently lib/ansible/galaxy/role.py checks roles_path and will
ignore paths that don't currently exist which it should not because
the path will attempt to be created by the role extraction process
(which is valid and expected behavior) and if unable to write at the
time of role extraction into the role_path, that error will be
handled properly at that point in the process.

Signed-off-by: Adam Miller <admiller@redhat.com>

* add test case for galaxy install with rolefile and rolepath

Verify we don't regress GitHub Issue #35217

Signed-off-by: Adam Miller <admiller@redhat.com>

* fix the integration test

Signed-off-by: Adam Miller <admiller@redhat.com>

* double quote for shellcheck glob warning

Signed-off-by: Adam Miller <admiller@redhat.com>

* fix galaxy install tests to not need remote resources

Signed-off-by: Adam Miller <admiller@redhat.com>

* make shellcheck sanity tests happy

Signed-off-by: Adam Miller <admiller@redhat.com>

* prep git global conf for running the galaxy install tests in docker

Signed-off-by: Adam Miller <admiller@redhat.com>

* move ansible-galaxy tests into their own target, make git conf non-global

Signed-off-by: Adam Miller <admiller@redhat.com>

* fix up tests based on feedback

Signed-off-by: Adam Miller <admiller@redhat.com>

* remove extra newline from aliases file

Signed-off-by: Adam Miller <admiller@redhat.com>
7 years ago
Nathaniel Case 4a79112e5c
Fix ios_facts return values (#35239)
* Revert model and serialnum to older version

* Add stacked versions of model and serialnum as separate facts

* Add unit test to check stacked output

* Alter model regex to address #34768
7 years ago
John R Barker a23c95023b
Module deprecation: docs, scheme and tests (#34100)
Enforce module deprecation.
After module has reached the end of it's deprecation cycle we will replace it with a docs stub.

* Replace deprecated modules with docs-only sub
* Use of deprecated past deprecation cycle gives meaningful message (see examples below)
* Enforce documentation.deprecation dict via `schema.py`
* Update `ansible-doc` and web docs to display documentation.deprecation
* Document that structure in `dev_guide`
* Ensure that all modules starting with `_` have a `deprecation:` block
* Ensure `deprecation:` block is only used on modules that start with `_`
* `removed_in` A string which represents when this module needs **deleting**
* CHANGELOG.md and porting_guide_2.5.rst list removed modules as well as alternatives
* CHANGELOG.md links to porting guide index

To ensure that meaningful messages are given to the user if they try to use a module at the end of it's deprecation cycle we enforce the module to contain:
```python
if __name__ == '__main__':
    removed_module()
```
7 years ago
Martin Krizek 7c83f006c0
Fix triggering parent's always with run_once set (#35464) 7 years ago
Matt Clay 359ff19484 Temporarily disable `influxdb_user` test.
The test interferes with the `uri` test.
7 years ago
Matt Clay 3b0dcf7f29 Test Windows 2012+ using Azure by default. 7 years ago
Stephen Granger 7fa09390b0 Elasticbeanstalk app (#31079)
* New AWS elasticbeanstalk app module

* Integration tests for elasticbeanstalk_app
7 years ago
Matt Clay 10f3a47eab Use static password for win_owner test. (#35482)
This will provide consistent results across test runs and
should avoid previously seen issues with password complexity
failures.
7 years ago
Abhijeet Kasurde becb31f34c nmcli: Allow setting ipv4.dhcp-client-id parameter (#34268)
Signed-off-by: Orion Poplawski <orion@cora.nwra.com>
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Matt Clay e98e757ec4 Fix win_regedit module and tests. (#35478) 7 years ago
Jordan Borean 4da19f2d6b Added code-smell check to verify filenames are allowed with Windows (#35436) 7 years ago
Adrian Likins b20ba105c2 intg tests for 'any_errors_fatal' (#25813)
* start adding intg tests for any_errors_fatal

* updates

* show captured output

flip conditional for on_includes

* cleanup/ci poke

* fix typos

* Add 'EXPECTED FAILURE' to tasks names for expected failures
7 years ago
Ed Costello d16bc1c3f4 New aws_ses_identity module to manage AWS Simple Email Service Identity (#31140)
* Add aws_ses_identity module

* Update CI alias, add BotoCoreError exception handling.

* Add SES and SNS permissions to hacking/aws_config to run aws_ses_identity integration tests
7 years ago
Ganesh Nalawade bbdddffa1e
Fix junos_facts integration test failure (#35469)
Hostname is not always configured on remote host
Instead add a assert statement to check if netconf
is configured for junos_facts.
7 years ago
Jean-Philippe Evrard 5f1254697d New module etcd3 (#35053)
This module uses etcd3 python library to do k/v manipulation on
an etcd3 cluster using version3 api.
7 years ago
Abhijeet Kasurde aa736c6944
VMware: add new module: vmware_host_acceptance (#35040)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Abhijeet Kasurde aac6d282e5
VMware: Add new module - vmware_vm_vm_drs_rule (#34177)
This adds a new module called vmware_vm_vm_drs_rule. This module add
affinity/antiaffinity rule for VM-VM in given cluster.

Fixes: #32109

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Abhijeet Kasurde 8549482482
VMware: add new module: vmware_host_package_facts (#35036)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Jordan Borean 9ee079f34d
further fixes to rename only where required (#35432) 7 years ago
Jordan Borean d902bd39a3
renamed test file to allow checkouts on Windows (#35430)
* renamed test file to allow checkouts on Windows

* used different name pattern to fix sanity issues
7 years ago
Abhijeet Kasurde 857d0fd62e
VMware: add new module: vmware_host_vmnic_facts (#34984)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Peter Sprygada c2d3b9cbd5
refactors nios api shared code to handle provider better (#35393)
* refactors nios api shared code to handle provider better

This change refactors the shared code to be easily shared between
modules, plugins and dynamic inventory scripts.  All parts now implement
the provider arguments uniformly.

This also provides a centralized fix to suppress urllib3 warnings coming
from the requests library implemented by infoblox_client

* fix up pep8 errors

* fix missing var name
7 years ago
Artem Zinenko 1f1402ea68 Integration tests for influxdb_user module (#35315)
* Added integration tests for influxdb_user
* Tests for idempotency checking and check mode
7 years ago
Pilou 47d8d8c36e Fix yum integration tests (#35177)
* use tests instead of filters

* Don't check 'rc', use success/failed tests

- yum module use 'fail_json' which set 'failed'
- 'rc' is for backward compatibility:
  bbd6b8bb42/lib/ansible/executor/task_executor.py (L571)
- besides yum module doesn't document any return values

* Allow to run tests twice in a row

ansible-test is executed with '--retry-on-error' switch, then tests must
be able to executed twice in a row.

Error was:
TASK [yum : install group] ***
ok: [testhost] => {
    "attempts": 1,
    "changed": false,
    "failed": false,
    "invocation": { [...] },
    "msg": "",
    "rc": 0,
    "results": []
}

TASK [yum : verify installation of the group] ***
fatal: [testhost]: FAILED! => {
    "assertion": "yum_result.changed",
    "attempts": 1,
    "changed": false,
    "evaluated_to": false,
    "failed": true
}
7 years ago
Jordan Borean 04d88755d5
fix win_user_right test for Azure (#35415) 7 years ago
Will Thames 56196e66bf [cloud] Improve results from ecs_taskdefinition_facts (#34337)
ecs_taskdefinition_facts should not populate ansible_facts with
so much information.

Better to just return the contents of the dict directly.

Reduce line lengths, use AnsibleAWSModule, don't reimplement
camel_dict_to_snake_dict.
7 years ago
Ghilli3 60d2a8b6a1 Fortinet FortiManager Scripting Module (#34518)
* Adding new code for new module and new module_utils with the pip pyfmg package

* Changed login and logout functionality and renamed mod_utils file as well as cleaned up PEP8 syntax

* Removing extra Ansible parameters and fixing more syntax issues

* Fixing more syntax issues and comparing against previous FTNT script module

* Changing import location to pass syntax checks

* Fixing pylint errors

* Removing test files

* Add unit tests and enabling a login session check within main in order to throw error if network connection exception

* Fixing syntax issues for adding unit tests

* Changing case for pip package requirements

* adding comments

* adding version restriction on pip package for testing

* adding version restriction on pip package for testing

* More comments

* Fixing documentation errors and add the ability to skip a test if it isn't present

* Fixing Pep8 error with whitespace (tab) in the row
7 years ago
Matt Martz 7404dc6767 Recursively remove args with omit as as their value, to match suboptions in argument_spec (#35299)
* Recursively remove args with omit as as their value, to match suboptions in argument_spec

* Add test for the new remove_omit function
7 years ago
Amol Kahat e8633b7a22 Added VLAN configuration. (#35343)
Fixes GH 22147

Signed-off-by: Amol Kahat <akahat@redhat.com>
7 years ago
Nathaniel Case 1f1e5c11a9
ios_command: Whitelist some commands starting with `configure` (#35363)
* Whitelist some commands starting with `configure`

* Add tests for conditional `configure` rejection
7 years ago
Dag Wieers 4fa02d581d Remove 'attempts' from non-looped tasks (#35316)
* Remove 'attempts' from non-looped tasks

* Use self._task.until to determine if we're in a loop

* Undo recent changes to Windows tests
7 years ago
Daniel Shepherd 892fc41190 [cloud] New module: Amazon Egress-Only Internet Gateway (ec2_vpc_egress_igw) (#23941)
* New module: ec2_vpc_egress_igw

* minor pep8 fix and doc update

* add test dir and files

* add tests for gateway module

* fix up return documentation per review

* remove HAS_BOTO3 stuff as it is handled in AnsibleAWSModule per review

* fix an error with failure message and add custom handler for non-existent vpc ID

* add additional tests and update tests per review

* ignore errors on clean up tasks

* update module copyright to newer format

* fix exception handling since BotoCoreError doesnt have response attribute

* actually fix exception handling this time so it works with Py3 as well
7 years ago
Jordan Borean 0fb916c35e
more Azure test fixes for Windows (#35386) 7 years ago
Thom Wiggers e2af5dfae0 Module to generate Diffie-Hellman parameters (#32620)
* Module to generate Diffie-Hellman parameters

Implements #32577

* Add integration tests for openssl_dhparam

* Slightly refactor check to prevent unnecessary regeneration

* Fix code smell in tests

Highly annoying to have to do this again and again and again as the rules change during the game

* Using module.run_command() and module.atomic_move() from a tempfile.

* Remove underscore variable

Ansible prefers dummy
7 years ago
Pierre-Louis Bonicoli 0db98d7d71 NPM integration tests: use ansible-ci-files 7 years ago
Matt Clay 573daf6280 Use ansible-ci-files for rpm_key test downloads. 7 years ago
Jordan Borean ea7d29e262 azure windows: changed pagefile to dynamically get the path (#35376) 7 years ago
Matt Clay b1d14d5b06 Fix failing zypper_repository integration test. 7 years ago
Matt Clay 7abdab6c9e Convert ansible-test compile into a sanity test. 7 years ago
Pilou 0ce8d389a4 azure_rm_dnsrecordset: fix broken import and minor updates (#34983)
* fix broken import

Error was:
lib/ansible/modules/cloud/azure/azure_rm_dnsrecordset.py:223:0: NameError: name 'ARecord' is not defined

* doc: use formatting functions

* remove unused dict
7 years ago
Dag Wieers 417accf88d Skip parameters that are being deprecated (#35319)
* Skip parameters that are being deprecated

So in most cases when parameters are deprecated, you may not want to
advertise them in the documentation. One reason for this is because
these parameters were not introduced within Ansible but predate
upstreaming them.

So this change avoids reporting parameters that are not documented and
are deprecated. It's only a small subset of the existing E322 errors.

* Add support for E323 with these changes

* Unsure about the other issues now

* Add better error message with E321

* Restore some erroneously remove files

* Readd false positives to ignore.txt
7 years ago
David Newswanger ed082af8c9
improved test coveraage for vyos_config (#35298) 7 years ago
Senthil Kumar Ganesan 2f46f8f944 Added support for new Ansible Infra (network_cli plugin, cliconf, module utils cleanup and test) for dellos10 Support t (#34915)
* Support for network_cli plugin and tests

* Fixed ansible-test * issues

* Fixed Pylint warning

* Fixed the sanity test errors

* Fix YAMLlinter issue - removed blank spaces

* Fixed Python 3 failures

* Fixed the PEP8 issue

* Fix sanity --test validate-modules

* Reverted the changes to the doc fragments
7 years ago
Abhijeet Kasurde 1f544ed6cc
VMware: Add new module : vmware_drs_rule_facts (#35337)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
7 years ago
Matt Davis 2a9ec6bdbf
fix Windows tests with hardcoded Administrator account (#35339)
* Admin account is not always called Administrator (eg Azure)
* this fixes some, but not all issues related to the Administrator account on non-English Windows as well (still numerous references to "Administrators" and other en-US Windows group names)
7 years ago
Ganesh Nalawade c216473c82
Fix ios integration test failures (#35333) 7 years ago
Kedar Kekan dd949c5b65
* adds missing params in a task (#35330) 7 years ago
Matt Clay e0010f15e4 Add pslint sanity test. (#35303)
* Add pslint sanity test.

* Fix `no-smart-quotes` sanity test.

* Add docs for `pslint` sanity test.
7 years ago
Yuwei Zhou 7c201fc9bc delete subnet should be idempotent (#35037) 7 years ago
Matt Clay e9e85625aa Disable failing azure_rm_postgresql* tests. 7 years ago
Matt Clay bbedb9aac4 Disable failing azure_rm_mysqlserver test. 7 years ago
Matt Clay 8ea0bfe9a3
Miscellaneous test fixes. (#35301)
* Add missing pylint test for invalid path.
* Fix syntax in integration test.
* Use Write-Output in win_script test script.
* Fix pylint in explain mode.
7 years ago
Matt Clay ebe925405c Disable failing azure_rm_mysqldatabase test. 7 years ago
Matt Clay cc65636a10 Add PSScriptAnalyzer to default container. 7 years ago
Tim Rupp bd09e67438
More bug fixes before 2.5 (#35260)
This patch includes more fixes for bugs that were identified in
the upcoming 2.5 release.
7 years ago
Kedar Kekan c643a5d628
* removes the console logging from cli run before netconf run is (#35290)
started
7 years ago
Matt Martz 1ac04ba52e
Don't skip an inventory source just because it has a comma (#35002)
* Don't skip an inventory source just because it has a comma, make sure it's also doesn't exist as a path. Fixes #34931

* Add integration test for inventory path with commas
7 years ago
Kedar Kekan 56eeaf1b2f
Changes to enable network_cli and netconf on iosxr integration tests. (#35269)
* * Changes to enable network_cli and netconf on modules.
* limits connection local for single TC per playbook.

* * adds a note on why only 1 TC is executed with connection: local
7 years ago
Claes Nästén 0582521f96 NSO: handle types for leaf-lists in nso_config (ValueBuilder) (#34986)
Fixes: #34985
7 years ago
Claes Nästén b7f815ba89 nso_config handle data.not_found in exists for nested lists (#35267)
Recent NSO can return data.not_found error on exists when parent list
entries does not exist. Handle this and return as false.

Fixes: #35264
7 years ago
saichint 0b30c42902 fix pim rp_address issues (#35248) 7 years ago
Colins-Git 7fac5cd7d2 Support for creation and modification of bridge and bridge slaves for nmcli (#34071)
Fixes: #31737
7 years ago
Zim Kalinowski b2ea28f1ad [new module] azure_rm_sqldatabase (#34611)
* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase

* updates to azure_rm_sqldatabase
7 years ago
Trishna Guha fd4fdbf01f
ios_logging handling platform difference (#35232)
* ios_logging handling platform difference

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

* fix unit test

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
Yuwei Zhou 6f67d68f5a azure_rm_networkinterface: support the multiple ip configuration (#32882)
* support the mutilple ip configuration

* Update azure_rm_networkinterface.py

* add test

* fix spell

* make the virtual network name more flexiable

* add test

* fix

* fix lint

* add test

* fix parameter

* deprecate the flatten ip configuration

* fix lint

* fix encoding

* fix mirror

* fix

* load model from common
7 years ago
Deiwin Sarjas e970ae102c ecs_ecr: Fix AWS ECR repository creation (#34798)
* ecs_ecr: Remove registry ID from create repository call

[Boto3 documentation][1] specifies 'repositoryName' as the only expected
argument. The `**build_kwargs(registry_id)` part also adds 'registryId' which,
when executed, fails with: 'Unknown parameter in input: “registryId”, must be
one of: repositoryName'.

[AWS API documentation][2] also lists only the 'repositoryName' parameter. I.e.
this is not a problem with the boto3 library.

The default registry ID for the account that's making the request will be used
when creating the rpository. This means that if the `registry_id` specified by
the user is different from the default registry ID, then the policy changes
following the repository creation would fail, because the repository will have
been created in one repository but subsequent calls try to modify it in
another. Added a safeguard against this scenario.

[1]: https://boto3.readthedocs.io/en/latest/reference/services/ecr.html#ECR.Client.create_repository
[2]: https://docs.aws.amazon.com/AmazonECR/latest/APIReference/API_CreateRepository.html

* Fix concurrent ECR integration tests

If the `ecr_name` is the same in multiple concurrent test runs, then they can
interfere with one another causing both to fail. The `resource_prefix` is
guaranteed to be unique for different jobs running in CI an so avoids this
issue while also making it easier to identify the test which created the
resource.
7 years ago
Ricardo Carrillo Cruz 33c4351a35
Add authorize and provider params to eos_l2_interface tests (#35249)
Otherwise this fail for connection local
7 years ago
Ricardo Carrillo Cruz eacb4d0a4a
Add become on eos_l2_interface tests (#35245) 7 years ago