Skip to content

Fixes Issue #8123 [Chore]: Use minimal images for E2E tests - #8232

Open
omsuneri wants to merge 12 commits into
cloudnative-pg:mainfrom
omsuneri:resolving-8123
Open

omsuneri wants to merge 12 commits into
cloudnative-pg:mainfrom
omsuneri:resolving-8123

Conversation

@omsuneri

@omsuneri omsuneri commented Aug 4, 2025

Copy link
Copy Markdown
Contributor

Fixes #8123 : Add support for minimal images in E2E tests, isolate Barman Cloud tests

What Changed

  • Labeled Barman Cloud tests (LabelBarmanCloud = "barman-cloud") to run them separately.

  • Tagged relevant tests like backup_restore_minio_test.go, etc., with the new label.

  • Added minimal image support in utils.go:

    • ShouldUseMinimalImages() to check env
    • GetPostgresImageForTest() to pick the right image
    • transformToMinimalImage() to switch to -minimal-bookworm variants
  • Updated E2E tests to use GetPostgresImageForTest() instead of reading POSTGRES_IMG directly.

Usage

Run core tests with minimal images:

export USE_MINIMAL_IMAGES=true
make e2e-test-kind

Run Barman Cloud tests with full images:

unset USE_MINIMAL_IMAGES
export LABEL_FILTERS="barman-cloud"
make e2e-test-kind

Run everything with full images (default):

unset USE_MINIMAL_IMAGES
make e2e-test-kind
  • Faster test runs
  • Clean separation between core PG tests and Barman Cloud
  • Aligns with the move to plugin-based Barman Cloud support

@gbartolini please review the changes and request if further refinements are required !!

omsuneri added 12 commits August 4, 2025 10:13
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
Signed-off-by: Om Santosh Suneri <[email protected]>
@omsuneri
omsuneri requested a review from a team August 4, 2025 05:17
@cnpg-bot cnpg-bot added backport-requested ◀️ This pull request should be backported to all supported releases release-1.22 labels Aug 4, 2025
@github-actions

github-actions Bot commented Aug 4, 2025

Copy link
Copy Markdown
Contributor

❗ By default, the pull request is configured to backport to all release branches.

  • To stop backporting this pr, remove the label: backport-requested ◀️ or add the label 'do not backport'
  • To stop backporting this pr to a certain release branch, remove the specific branch label: release-x.y

@dosubot dosubot Bot added size:M This PR changes 30-99 lines, ignoring generated files. E2E tests E2E tests tickets for easy triage on release process labels Aug 4, 2025
@omsuneri

omsuneri commented Aug 4, 2025

Copy link
Copy Markdown
Contributor Author

@gbartolini @sxd @gabriele-wolfox please review these changes !!

@sxd

sxd commented Aug 11, 2025

Copy link
Copy Markdown
Contributor

@omsuneri did you trigger a full run the E2E tests locally ?

@omsuneri

Copy link
Copy Markdown
Contributor Author

@sxd nope I just rely on the gh actions workflow
If you want I can do that

@omsuneri

Copy link
Copy Markdown
Contributor Author

@sxd i tried out the e2e tests and they run well !!

@github-actions

github-actions Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Warning

Linked issue missing.

Reference one in the PR body using a keyword (Closes / Fixes / Resolves / Refs / See) followed by #<issue_id> or owner/repo#<issue_id>.

Alternatively, apply the no-issue label to skip this check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport-requested ◀️ This pull request should be backported to all supported releases E2E tests E2E tests tickets for easy triage on release process release-1.28 release-1.30 size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Chore]: Use minimal images for E2E tests

4 participants