Skip to content

Refactor admin_debug_packages tests to match structured output format#342

Open
prasant750h wants to merge 1 commit intodell:automation-v2.1.0.0from
prasant750h:automation-v2.1.0.0
Open

Refactor admin_debug_packages tests to match structured output format#342
prasant750h wants to merge 1 commit intodell:automation-v2.1.0.0from
prasant750h:automation-v2.1.0.0

Conversation

@prasant750h
Copy link
Copy Markdown

  • Modified test_admin_debug_packages.py to use structured details format
  • Changed output from multiple log.check() calls to single details string
  • Updated functional group display from '═══ group ═══' to '[group]' format
  • Enhanced node display with proper indentation showing IP and status
  • All three test cases now follow consistent format matching test_pam_slurm_adopt
  • Fixed pylint issues: trailing whitespace, f-string without interpolation
  • Added pylint disable for import-error and too-many-locals
  • Code now passes pylint with 10.00/10 rating

Test output improvements:

  • test_admin_debug_packages_config: Shows config existence and presence
  • test_admin_debug_packages_json: Lists all packages with proper formatting
  • test_debug_packages_installed: Groups nodes by functional group with detailed status

- Modified test_admin_debug_packages.py to use structured details format
- Changed output from multiple log.check() calls to single details string
- Updated functional group display from '═══ group ═══' to '[group]' format
- Enhanced node display with proper indentation showing IP and status
- All three test cases now follow consistent format matching test_pam_slurm_adopt
- Fixed pylint issues: trailing whitespace, f-string without interpolation
- Added pylint disable for import-error and too-many-locals
- Code now passes pylint with 10.00/10 rating

Test output improvements:
- test_admin_debug_packages_config: Shows config existence and presence
- test_admin_debug_packages_json: Lists all packages with proper formatting
- test_debug_packages_installed: Groups nodes by functional group with detailed status
}

# =============================================================================
def get_packages_from_json(host) -> List[str]:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you create a dynamic function to verify in aarch64 cluster also

# Path to admin_debug_packages.json inside omnia_core container
ADMIN_DEBUG_PACKAGES_JSON = (
"/opt/omnia/input/project_default/config"
"/x86_64/rhel/10.0/admin_debug_packages.json"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add for aarch64 as well

)

# =============================================================================
def test_admin_debug_packages_config(host):
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not actually a test case. You can check this as a part of function [it can be a helper function as well]. also core module have that functionality, please check and utilize it.

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