Commit Graph

31 Commits (cd8161a94827bd8dbae53610318f5957b56b8b98)

Author SHA1 Message Date
Nilashish Chakraborty 9365c0f468
New module for BGP configuration management in Arista EOS (#52722)
* New module for BGP in EOS

Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>

* Add function to validate input

Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>

* Fix line indentation

Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>

* Add integration tests

Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>

* Fix CI

Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>

* Fix sanity test failure

Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>

* Remove unused code

Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>
6 years ago
Nathaniel Case 9702893729
Remove deprecated options from modules (#50246)
* Remove deprecated options from modules

* Update tests

* Add porting guide notes
6 years ago
Toshio Kuratomi 3fba006207 Update bare exceptions to specify Exception.
This will keep us from accidentally catching program-exiting exceptions
like KeyboardInterupt and SystemExit.
6 years ago
Matt Clay 3033fd96b0
Move unit test compat code out of `lib/ansible/`. (#46996)
* Move ansible.compat.tests to test/units/compat/.
* Fix unit test references to ansible.compat.tests.
* Move builtins compat to separate file.
* Fix classification of test/units/compat/ dir.
6 years ago
Ganesh Nalawade af3f510316
nxos cliconf plugin refactor (#43203)
* nxos cliconf plugin refactor

Fixes #39056

*  Refactor nxos cliconf plugin as per new api definition
*  Minor changes in ios, eos, vyos cliconf plugin
*  Change nxos httpapi plugin edit_config method to be in sync with
   nxos cliconf edit_config

* Fix CI failure

* Fix unit test failure and review comment
6 years ago
Ganesh Nalawade c068b88b38
Update eos, ios, vyos cliconf plugin (#42300)
* Update eos cliconf plugin methods

*  Refactor eos cliconf plugin
*  Changes in eos module_utils as per cliconf plugin refactor

* Fix unit test and sanity failures

* Fix review comment
6 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
Pilou a5c9726502 Unit tests: share common code (#31456)
* move set_module_args to units.modules.utils
* unit tests: reuse set_module_args
* unit tests: mock exit/fail_json in module.utils.ModuleTestCase
* unit tests: use module.utils.ModuleTestCase
* unit tests: fix 'import shadowed by loop variable'
7 years ago
Dave Thelen 2c99cbc874 eos_eapi: adding the desired state config to the new vrf fixes #32111 (#32112)
* adding the desired state config to the new vrf fixes #32111

* fix default vrf initial configured

* add unit test
7 years ago
Ganesh Nalawade 3ff527b1d2 Fixes #30281 eos_banner integration test failure (#30283)
* Fixes #30281 Configure login prompt for eos_banner

* Fix unit test

* Fix pep8 issue
7 years ago
Trishna Guha 252efcebf5 module should fail if eos_user is added without configured_password or nopassword or sshkey (#28780)
* module should fail if eos_user is added without configured_password or nopassword or sshkey

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

* fix eos_user unit test

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

* fix eos_user integration test

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
7 years ago
David Newswanger b818e986b6 Change network *_user modules to use configured_password to set a users password (#28187)
* WIP, update eos_user args

* refactor password for ios_user

* add eos tests, fix ios tests

* fixed password check

* refactor iosxr_user password

* fixed password arg for nxos

* [WIP] fix vyos_user password

* fix vyos tests

* update docs for net_user

* fix typo

* fix eos tests

* add warning when attempting to use password arg

* fix sanity/unit tests

* fix eos unit tests

* fix vyos_user aggregate

* fix typo in eos documentation string

* re add configured_password to vyos tests after rebase
7 years ago
Trishna Guha ce3d1c6ba0 eos_user fix username param (#28114)
* eos_user fix username param

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

* Add setup eos_user test and rename username for consistency

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

* update unit test and pep8 fix

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

* pep8 fix
7 years ago
Peter Sprygada 3bbb32cac5 fixes error when trying to run show start over eapi (#26800) 7 years ago
Ricardo Carrillo Cruz b81209c187 Fix multiple EOS EAPI code and test issues (#26651) 7 years ago
Nathaniel Case f52dcef7ba Actually check for equality on empty commands array (#25308) 7 years ago
Dag Wieers 4efec414e7 test/: PEP8 compliancy (#24803)
* test/: PEP8 compliancy

- Make PEP8 compliant

* Python3 chokes on casting int to bytes (#24952)

But if we tell the formatter that the var is a number, it works
7 years ago
Ricardo Carrillo Cruz 604a38cac1 Implement eos_banner for EAPI (#22609)
On EAPI, the multi-line commands are expected to be a dict,
with key/value pairs 'cmd'/'input' .
This change implements that behaviour and fixes the idempotency
on EAPI as well.

Fixes #22494
8 years ago
Ricardo Carrillo Cruz c57729944b Fix the eos_banner idempotency (#22413)
The map_config_to_obj calls the run_commands  helper function,
which returns a list of results.
However, the map_params_to_obj return a single string.
Therefore, the comparison between the two datasets could never be equal,
breaking idempotency.
Also, the 'no banner' command should be run on absent only if there's a banner
text set.

Fixes #22194
8 years ago
Peter Sprygada 6c8025ce5c adds eos_system integration tests (#22214)
* adds integration test cases
* updates eos_system with minor bug fixes
8 years ago
Matt Clay a5e3d13adc Remove shebangs from unit tests. 8 years ago
Peter Sprygada 16a39639f5 fixes minor bugs in eos_eapi module (#21925)
* module will now check protocol running state before return
* warns on config argument no longer being needed
* lots of integration test cases updated
* updates unit and integration test cases for state check

fixes #21908
8 years ago
Peter Sprygada e1a2c6e1d3 roll up of fixes for eos modules (#21406)
* fixes issue with load_provider() not checking for an existing key
* adds updates to eos_config results key
* lots of minor syntax fixes in eos shared module
* adds eos_argument_spec to eos_eapi

fixes #21402
8 years ago
Peter Sprygada 14b942f3fb updates eos modules to use socket (#21197)
* updates eos modules to use persistent connection socket
* removes split eos shared module and combines into one
* adds singular eos doc frag (eos_local to be removed after module updates)
* updates unit test cases
8 years ago
Peter Sprygada d226f31a0f fixes ios and eos command modules (#20989)
* returns support for prompt/response over cli
* now sends native dict instead of str command
* fixes issue with run_commands() in ios to jsonify request
* updates unit test cases
8 years ago
Peter Sprygada 85d78390f9 adds new module eos_system (#20797)
* provides declarative resource for configuring eos system parameters
* supports network_cli connection plugin only
* adds unit tests for module using mock interfaces
8 years ago
Peter Sprygada d2dd2fbe49 adds module eos_banner (#20796)
* new module allows for configuration of eos multiline banners
* adds unit test cases for module
8 years ago
Peter Sprygada 6c89c587cc refactors eos_config module to use network_cli (#20741)
* update eos_config to use eapi exclusively and remove cli transport
* add unit test cases for eos_config
* updates action plugin to handle both eapi and network_cli connections
8 years ago
Peter Sprygada 271c0c4574 new module eos_user (#20759)
* adds new module for managing local user accounts on eos devices
* adds unit test cases for module

This module only supports network_cli
8 years ago
Peter Sprygada c8dcc7f5d6 refactors eos_command module (#20739)
* eos_command now uses network_cli connection plugin
* adds unit test cases for eos_command module
8 years ago
Peter Sprygada 57660abf33 refactor eos_eapi module (#20740)
* eos_eapi module now requires network_cli plugin
* adds unit test cases for eos_eapi module
8 years ago