Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow running admin show arguments in check_mode #407

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

wrouesnel
Copy link

SUMMARY

The show command filter was unaware of admin class commands which are invoked by admin show. This patch fixes the problem to allow these commands in check mode.

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

cisco.iosxr.iosxr_command

ADDITIONAL INFORMATION
cisco.iosxr.iosxr_command:
  commands:
  - admin show running-config
  check_mode: true
  register: admin_running_config

produces

[WARNING]: Only show commands are supported when using check mode, not executing admin show running-config

With the changes here, the command now runs successfully.

wrouesnel and others added 2 commits June 28, 2023 14:01
The `show` command filter was unaware of `admin` class commands which are invoked by `admin show`. This patch fixes the problem to allow these commands in check mode.
@softwarefactory-project-zuul
Copy link

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/5637ccb41bd1495e904b29ed71e894d1

✔️ ansible-galaxy-importer SUCCESS in 3m 57s
✔️ build-ansible-collection SUCCESS in 8m 48s
✔️ ansible-tox-linters SUCCESS in 10m 45s

Copy link

codecov bot commented Nov 17, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 76.12%. Comparing base (1bba67a) to head (cf84cf7).

❗ Current head cf84cf7 differs from pull request most recent head 710945e. Consider uploading reports for the commit 710945e to get more accurate results

Additional details and impacted files
@@            Coverage Diff            @@
##           main     #407       +/-   ##
=========================================
+ Coverage      0   76.12%   +76.12%     
=========================================
  Files         0      166      +166     
  Lines         0    11242    +11242     
=========================================
+ Hits          0     8558     +8558     
- Misses        0     2684     +2684     

see 166 files with indirect coverage changes

Copy link

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/1705a0434472454a84752d4bb0da9d5d

✔️ ansible-galaxy-importer SUCCESS in 5m 26s
✔️ build-ansible-collection SUCCESS in 9m 54s
✔️ ansible-tox-linters SUCCESS in 12m 03s

@Ruchip16 Ruchip16 self-requested a review April 10, 2024 10:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants