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

Capsule N-Minus testing #12939

Merged
merged 1 commit into from
Mar 11, 2024
Merged

Conversation

jyejare
Copy link
Member

@jyejare jyejare commented Oct 18, 2023

Changes include:

  • A new pytest plugin for Capsule N-minus testing that would smart collect all capsule specific tests excluding few.
    • New option of --n-minus for collecting only capsule specific tests
    • tests using the caspule_factory are collected
    • destructive, maintain and puppet tests are excluded since they need a separate satellite
  • Introduces new setting hostname in capsule conf to take capsule hostname given from CI.
  • _target_capsule_host context manager now returns the cached capsule taken from CI instead of spinning of new capsule for everytime.
  • The CI capsule is registered once/cached to CDN for RHEL contents needed by some tests at the start of the n-minus testing and would be unregistered at the end of test session.
  • Since we are using single capsule already integrated with satellite in CI, we are escaping the capsule setup from fixtures for n-minus testing
  • Some test amendments for nminus testing.

@jyejare jyejare requested a review from a team as a code owner October 18, 2023 13:46
@jyejare jyejare marked this pull request as draft October 18, 2023 13:46
@jyejare jyejare added 6.11.z Introduced in or relating directly to Satellite 6.11 CherryPick PR needs CherryPick to previous branches 6.12.z Introduced in or relating directly to Satellite 6.12 6.13.z Introduced in or relating directly to Satellite 6.13 6.14.z Introduced in or relating directly to Satellite 6.14 and removed 6.11.z Introduced in or relating directly to Satellite 6.11 labels Oct 18, 2023
@jyejare jyejare force-pushed the capsule_n-minus branch 4 times, most recently from 90f01c1 to b02aa45 Compare October 27, 2023 17:58
@lpramuk
Copy link
Contributor

lpramuk commented Oct 30, 2023

N-1 testing should be part of Upgrades, more precisely upgrade-scenarios

Otherwise this would be just another postupgrade (aka. alltiers) test

@jyejare
Copy link
Member Author

jyejare commented Nov 2, 2023

@lpramuk As discussed, we need both the combinations of Upgrade Scenarios and Upgrade All Tiers (Caspule specifics) to test N-minus testing.

So this PR take cares of All Tier testing with old capsule. We should be able to run existing capsule upgrade scenario without any changes though. We shall be taking care of caspule upgrade scenario in separate PR if needed !

Copy link
Contributor

@lpramuk lpramuk left a comment

Choose a reason for hiding this comment

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

Please replace request.config.option.n_minus (cmdline option usage) by way more generic request.node.get_closest_marker(name='destructive')

pytest_fixtures/core/sat_cap_factory.py Outdated Show resolved Hide resolved
robottelo/hosts.py Outdated Show resolved Hide resolved
@jyejare jyejare added the 6.15.z Introduced in or relating directly to Satellite 6.15 label Jan 5, 2024
@jyejare jyejare marked this pull request as ready for review January 5, 2024 14:22
@jyejare jyejare requested a review from a team as a code owner January 5, 2024 14:22
@jyejare jyejare force-pushed the capsule_n-minus branch 2 times, most recently from cfb0993 to 25ba06c Compare January 5, 2024 15:02
@jyejare
Copy link
Member Author

jyejare commented Jan 5, 2024

trigger: test-robottelo
pytest: --uses-fixtures capsule_factory tests/foreman/api

1 similar comment
@jyejare
Copy link
Member Author

jyejare commented Jan 8, 2024

trigger: test-robottelo
pytest: --uses-fixtures capsule_factory tests/foreman/api

@jyejare
Copy link
Member Author

jyejare commented Jan 9, 2024

trigger: test-robottelo
pytest: --uses-fixtures capsule_factory tests/foreman/api
provisioning: true

@jyejare jyejare added the Framework Changes A modification of the robottelo framework label Jan 9, 2024
@jyejare jyejare force-pushed the capsule_n-minus branch 2 times, most recently from 4871a7b to 9cb4be0 Compare March 11, 2024 10:45
@Gauravtalreja1 Gauravtalreja1 merged commit 6426265 into SatelliteQE:master Mar 11, 2024
6 of 7 checks passed
github-actions bot pushed a commit that referenced this pull request Mar 11, 2024
(cherry picked from commit 6426265)
github-actions bot pushed a commit that referenced this pull request Mar 11, 2024
(cherry picked from commit 6426265)
jyejare added a commit that referenced this pull request Mar 12, 2024
(cherry picked from commit 6426265)
jyejare added a commit that referenced this pull request Mar 12, 2024
Capsule N-Minus testing (#12939)

(cherry picked from commit 6426265)

Co-authored-by: Jitendra Yejare <[email protected]>
jyejare added a commit to jyejare/robottelo that referenced this pull request Mar 12, 2024
jyejare added a commit to jyejare/robottelo that referenced this pull request Mar 12, 2024
Gauravtalreja1 pushed a commit that referenced this pull request Mar 12, 2024
Gauravtalreja1 pushed a commit that referenced this pull request Mar 12, 2024
Gauravtalreja1 pushed a commit that referenced this pull request Mar 12, 2024
Capsule N-Minus testing (#12939)

(cherry picked from commit 6426265)

Co-authored-by: Jitendra Yejare <[email protected]>
shweta83 pushed a commit to shweta83/robottelo that referenced this pull request Apr 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.12.z Introduced in or relating directly to Satellite 6.12 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 CherryPick PR needs CherryPick to previous branches Framework Changes A modification of the robottelo framework 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.

7 participants