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.15.z][Combined Jenkins Ask] Capsule testing for sanity (#15948) #16420

Merged
merged 1 commit into from
Sep 23, 2024

Conversation

jyejare
Copy link
Member

@jyejare jyejare commented Sep 19, 2024

Problem Statement

Caspule Test isnt a part of sanity testing due to several reasons:

  1. Most test cases were dependent on Satellite and not on capsule
  2. The running time for sanity for separate capsule checkout and installation, configuration exceeds our target sanity runtime

Solution

Adding capsule installer test as part of sanity since Sanity is replacing bats tests in jenkins migration in delivery.

Related Issues

@jyejare jyejare requested review from a team as code owners September 19, 2024 09:40
@jyejare jyejare added No-CherryPick PR doesnt need CherryPick to previous branches Failed_AutoCherryPick Issue for failed/conflicted auto cherry pick of PRs 6.15.z Introduced in or relating directly to Satellite 6.15 labels Sep 19, 2024
@jyejare
Copy link
Member Author

jyejare commented Sep 19, 2024

trigger: test-robottelo
pytest: tests/foreman -m build_sanity

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 8730
Build Status: UNSTABLE
PRT Comment: pytest tests/foreman -m build_sanity --external-logging
Test Result : === 11 passed, 5455 deselected, 5572 warnings, 1 error in 2570.49s (0:42:50) ===

@Satellite-QE Satellite-QE added the PRT-Failed Indicates that latest PRT run is failed for the PR label Sep 19, 2024
* Capsule Sanity Test from installer

* Design Change: only count change

* Satellite Maintain fapolicyd package installation
@jyejare
Copy link
Member Author

jyejare commented Sep 19, 2024

trigger: test-robottelo
pytest: tests/foreman -m build_sanity

deploy_args = get_deploy_args(request)
with Broker(**deploy_args, host_class=Satellite, _count=2) as hosts:
yield hosts
if 'build_sanity' not in request.config.option.markexpr:
Copy link
Contributor

Choose a reason for hiding this comment

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

@jyejare This is not a good approach. This change will cause unnecessary call to module_target_sat and extra checkout in normal automation run.

Comment on lines +1358 to +1360
if satellite.execute('rpm -q satellite-maintain').status == 0:
# Installing the rpm on existing sat needs sat-maintain perms
cmmd = 'satellite-maintain packages install -y fapolicyd'
Copy link
Contributor

@jameerpathan111 jameerpathan111 Sep 19, 2024

Choose a reason for hiding this comment

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

This is wrong, there's won't be any satellite related packages installed on the rhel machine. It has to be done through dnf. Satellite(including satellite-maintain) packages install is done in later steps.

Suggested change
if satellite.execute('rpm -q satellite-maintain').status == 0:
# Installing the rpm on existing sat needs sat-maintain perms
cmmd = 'satellite-maintain packages install -y fapolicyd'

@@ -1381,8 +1383,8 @@ def sat_default_install(module_sat_ready_rhels):
'scenario satellite',
f'foreman-initial-admin-password {settings.server.admin_password}',
]
install_satellite(module_sat_ready_rhels[0], installer_args)
sat = module_sat_ready_rhels[0]
sat = module_sat_ready_rhels.pop()
Copy link
Contributor

Choose a reason for hiding this comment

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

Why are we using pop here. It'll remove Satellite from module_sat_ready_rhels, this could be used somewhere later in some other tests.

@Satellite-QE
Copy link
Collaborator

PRT Result

Build Number: 8733
Build Status: SUCCESS
PRT Comment: pytest tests/foreman -m build_sanity --external-logging
Test Result : ======= 12 passed, 5455 deselected, 5789 warnings in 3778.60s (1:02:58) ========

@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 Sep 19, 2024
@JacobCallahan
Copy link
Member

@jameerpathan111 this is a cherry-pick, so should be merged as-is. @jyejare can then address your feedback in a new PR against master, which will then be cherry-picked back on top of this.

With that in mind, please collect your feedback and file a new issue with everything.

@jameerpathan111
Copy link
Contributor

With that in mind, please collect your feedback and file a new issue with everything.

Sure

@Gauravtalreja1
Copy link
Collaborator

@jyejare @JacobCallahan As this is a manual cherrypick only, so how about we handle the feedback from @jameerpathan111 here only and open a separate PR to address in master/6.16.z only, that way we could avoid more cherrypick PRs :)

@JacobCallahan
Copy link
Member

I'll leave that up to @jyejare

@jyejare
Copy link
Member Author

jyejare commented Sep 20, 2024

@Gauravtalreja1 I dont see any immediate blocker for merging this one from Jameers comment.

Max there would be an increase in total time for installer tests.

@ogajduse ogajduse merged commit fc36c12 into SatelliteQE:6.15.z Sep 23, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.15.z Introduced in or relating directly to Satellite 6.15 Failed_AutoCherryPick Issue for failed/conflicted auto cherry pick of PRs 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.

[Failed-AutoCherryPick] - [Combined Jenkins Ask] Capsule testing for sanity
7 participants