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

[6.16.z] Fix cli yum repo authentication test #16769

Merged

Conversation

Satellite-QE
Copy link
Collaborator

Cherrypick of PR: #16640

Problem Statement

'generator' object has no attribute 'copy'

Solution

There were multiple levels to this error:

  • fix parametrization error
    AttributeError: 'generator' object has no attribute 'copy'
  • fix assertion
  • filter invalid parametrizations by adding 'yum_compatible' flag
    • 'latin-1' codec can't encode characters
    • Validation failed: Upstream password requires upstream username be set.
    • Validation failed: Upstream username is too long (maximum is 255 characters)

What was sadly not done:

  • make parametrization ids readable for meanigful debugging

Related Issues

PRT test
tests/foreman/cli/test_repository.py::TestRepository::test_negative_synchronize_auth_yum_repo

There were multiple levels to this error:

* fix parametrization error
  AttributeError: 'generator' object has no attribute 'copy'
* fix assertion
* filter invalid parametrizations by adding 'yum_compatible' flag
  - 'latin-1' codec can't encode characters
  - Validation failed: Upstream password requires upstream username be set.
  - Validation failed: Upstream username is too long (maximum is 255 characters)

What was sadly not done:
* make parametrization ids readable for meanigful debugging

(cherry picked from commit 1b4ad63)
@Satellite-QE Satellite-QE requested review from a team as code owners October 24, 2024 17:26
@Satellite-QE Satellite-QE added 6.16.z Introduced in or relating directly to Satellite 6.16 Auto_Cherry_Picked Automatically cherrypicked PR using GHA No-CherryPick PR doesnt need CherryPick to previous branches labels Oct 24, 2024
@Satellite-QE
Copy link
Collaborator Author

trigger: test-robottelo
pytest: tests/foreman/cli/test_repository.py -k test_negative_synchronize_auth_yum_repo

@Satellite-QE
Copy link
Collaborator Author

PRT Result

Build Number: 9153
Build Status: SUCCESS
PRT Comment: pytest tests/foreman/cli/test_repository.py -k test_negative_synchronize_auth_yum_repo --external-logging
Test Result : ========= 2 passed, 116 deselected, 173 warnings in 1365.20s (0:22:45) =========

@Satellite-QE Satellite-QE added the PRT-Passed Indicates that latest PRT run is passed for the PR label Oct 24, 2024
@dosas dosas merged commit 58e0842 into 6.16.z Oct 24, 2024
16 checks passed
@dosas dosas deleted the cherry-pick-6.16.z-1b4ad6332ce4ec87a2f637467bd61b213295a16c branch October 24, 2024 19:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.16.z Introduced in or relating directly to Satellite 6.16 Auto_Cherry_Picked Automatically cherrypicked PR using GHA No-CherryPick PR doesnt need CherryPick to previous branches PRT-Passed Indicates that latest PRT run is passed for the PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants