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

Fix Discovery Tests #16605

Merged
merged 1 commit into from
Nov 13, 2024
Merged

Conversation

shweta83
Copy link
Contributor

@shweta83 shweta83 commented Oct 8, 2024

Problem Statement

Discovery tests were failing with hussh backend as the shell didn't have stdout attribute and also because of a bug in hussh: JacobCallahan/Hussh#26

Solution

Updated the tests to exit the shell contextmanager and read shell.result.stdout. Also, because of the bug, we need to explicitly close the shell before exiting contextmanager.

Related Issues

@shweta83 shweta83 requested a review from a team as a code owner October 8, 2024 04:22
@shweta83
Copy link
Contributor Author

shweta83 commented Oct 8, 2024

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host[rhel8-ipv4-bios-discovery]
"provisioning": true

@shweta83 shweta83 added CherryPick PR needs CherryPick to previous branches 6.16.z Introduced in or relating directly to Satellite 6.16 labels Oct 8, 2024
@shweta83 shweta83 marked this pull request as draft October 8, 2024 04:23
@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 8889
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host[rhel8-ipv4-bios-discovery] --external-logging
Test Result : =========== 1 deselected, 10 warnings, 1 error in 617.93s (0:10:17) ============

@Satellite-QE Satellite-QE added the PRT-Failed Indicates that latest PRT run is failed for the PR label Oct 8, 2024
@shweta83
Copy link
Contributor Author

shweta83 commented Oct 8, 2024

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host
"provisioning": true
env:
    ROBOTTELO_server__deploy_arguments__deploy_rhel_version: '8'
    ROBOTTELO_server__deploy_arguments__deploy_sat_version: '6.16'

@shweta83
Copy link
Contributor Author

shweta83 commented Oct 8, 2024

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host
provisioning: true
env:
    ROBOTTELO_server__deploy_arguments__deploy_rhel_version: '8'
    ROBOTTELO_server__deploy_arguments__deploy_sat_version: '6.16'

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 8890
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging
Test Result : ========== 4 deselected, 35 warnings, 4 errors in 4738.30s (1:18:58) ===========

@Gauravtalreja1
Copy link
Collaborator

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host
provisioning: true
env:
    ROBOTTELO_server__deploy_arguments__deploy_rhel_version: '8'
    ROBOTTELO_server__deploy_arguments__deploy_sat_version: '6.16'
    BROKER_SSH_BACKEND: hussh

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 8898
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 35 warnings, 4 errors in 4722.20s (1:18:42) ==================

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 8908
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 35 warnings, 4 errors in 4706.57s (1:18:26) ==================

@shweta83
Copy link
Contributor Author

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host
provisioning: true
env:
    ROBOTTELO_server__deploy_arguments__deploy_rhel_version: '8'
    ROBOTTELO_server__deploy_arguments__deploy_sat_version: '6.16'
    BROKER_SSH_BACKEND: hussh

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9138
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 35 warnings, 4 errors in 4744.65s (1:19:04) ==================

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9144
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 33 warnings, 4 errors in 4628.24s (1:17:08) ==================

@shweta83 shweta83 marked this pull request as ready for review November 12, 2024 06:45
@shweta83 shweta83 requested a review from a team as a code owner November 12, 2024 06:45
@shweta83
Copy link
Contributor Author

shweta83 commented Nov 12, 2024

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host
provisioning: true
env:
    ROBOTTELO_server__deploy_arguments__deploy_rhel_version: '9'
    BROKER_SSH_BACKEND: hussh

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9329
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 35 warnings, 4 errors in 4775.78s (1:19:35) ==================

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9331
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 35 warnings, 4 errors in 4760.52s (1:19:20) ==================

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9334
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 35 warnings, 4 errors in 4774.49s (1:19:34) ==================

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9336
Build Status: SUCCESS
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py::TestDiscoveredHost::test_positive_provision_pxe_host --external-logging --include-onprem-provisioning
Test Result : ================= 4 passed, 389 warnings in 3366.96s (0:56:06) =================

@Satellite-QE Satellite-QE added PRT-Passed Indicates that latest PRT run is passed for the PR and removed PRT-Failed Indicates that latest PRT run is failed for the PR labels Nov 12, 2024
Copy link
Contributor

@shubhamsg199 shubhamsg199 left a comment

Choose a reason for hiding this comment

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

Ack, PRT 9336 passed

@SatelliteQE SatelliteQE deleted a comment from shweta83 Nov 13, 2024
@amolpati30 amolpati30 self-requested a review November 13, 2024 08:27
@shweta83
Copy link
Contributor Author

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py --external-logging --include-onprem-provisioning
provisioning: true
env:
    BROKER_SSH_BACKEND: hussh

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9345
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py --external-logging --include-onprem-provisioning --external-logging --include-onprem-provisioning
Test Result : = 5 failed, 9 passed, 1 deselected, 1428 warnings, 1 error in 6892.35s (1:54:52) =

@Gauravtalreja1
Copy link
Collaborator

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py --external-logging --include-onprem-provisioning -m on_premises_provisioning
env:
    ROBOTTELO_server__deploy_arguments__deploy_rhel_version: '9'
    ROBOTTELO_server__deploy_arguments__deploy_sat_version: '6.16'
    ROBOTTELO_server__deploy_arguments__deploy_snap_version: '9.0'
    BROKER_SSH_BACKEND: hussh

@Gauravtalreja1
Copy link
Collaborator

trigger: test-robottelo
pytest: tests/foreman/api/test_discoveredhost.py --external-logging --include-onprem-provisioning -m on_premises_provisioning
provisioning: true
env:
    ROBOTTELO_server__deploy_arguments__deploy_rhel_version: '9'
    ROBOTTELO_server__deploy_arguments__deploy_sat_version: '6.16'
    ROBOTTELO_server__deploy_arguments__deploy_snap_version: '9.0'
    BROKER_SSH_BACKEND: hussh

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 9347
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman/api/test_discoveredhost.py --external-logging --include-onprem-provisioning -m on_premises_provisioning --external-logging --include-onprem-provisioning
Test Result : ==== 1 failed, 9 passed, 5 deselected, 1331 warnings in 6593.00s (1:49:52) =====

@shweta83 shweta83 added 6.13.z Introduced in or relating directly to Satellite 6.13 6.14.z Introduced in or relating directly to Satellite 6.14 6.15.z Introduced in or relating directly to Satellite 6.15 TestFailure Issues and PRs related to a test failing in automation AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing labels Nov 13, 2024
@Gauravtalreja1 Gauravtalreja1 merged commit 41ec8b6 into SatelliteQE:master Nov 13, 2024
13 of 14 checks passed
github-actions bot pushed a commit that referenced this pull request Nov 13, 2024
(cherry picked from commit 41ec8b6)
github-actions bot pushed a commit that referenced this pull request Nov 13, 2024
(cherry picked from commit 41ec8b6)
github-actions bot pushed a commit that referenced this pull request Nov 13, 2024
(cherry picked from commit 41ec8b6)
github-actions bot pushed a commit that referenced this pull request Nov 13, 2024
(cherry picked from commit 41ec8b6)
Gauravtalreja1 pushed a commit that referenced this pull request Nov 13, 2024
Fix Discovery Tests (#16605)

(cherry picked from commit 41ec8b6)

Co-authored-by: Shweta Singh <[email protected]>
Gauravtalreja1 pushed a commit that referenced this pull request Nov 13, 2024
Fix Discovery Tests (#16605)

(cherry picked from commit 41ec8b6)

Co-authored-by: Shweta Singh <[email protected]>
Gauravtalreja1 pushed a commit that referenced this pull request Nov 13, 2024
Fix Discovery Tests (#16605)

(cherry picked from commit 41ec8b6)

Co-authored-by: Shweta Singh <[email protected]>
Gauravtalreja1 pushed a commit that referenced this pull request Nov 13, 2024
Fix Discovery Tests (#16605)

(cherry picked from commit 41ec8b6)

Co-authored-by: Shweta Singh <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.13.z Introduced in or relating directly to Satellite 6.13 6.14.z Introduced in or relating directly to Satellite 6.14 6.15.z Introduced in or relating directly to Satellite 6.15 6.16.z Introduced in or relating directly to Satellite 6.16 AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing CherryPick PR needs CherryPick to previous branches PRT-Failed Indicates that latest PRT run is failed for the PR TestFailure Issues and PRs related to a test failing in automation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants