Skip to content

chore(tests): Have tests set the flag so they run in CI#19685

Merged
dashrews78 merged 2 commits intomasterfrom
dashrews/virt-machine-run-tests
Mar 30, 2026
Merged

chore(tests): Have tests set the flag so they run in CI#19685
dashrews78 merged 2 commits intomasterfrom
dashrews/virt-machine-run-tests

Conversation

@dashrews78
Copy link
Copy Markdown
Contributor

@dashrews78 dashrews78 commented Mar 30, 2026

Description

Tests no longer require ROX_VIRTUAL_MACHINES_ENHANCED_DATA_MODEL=true
to be set externally. Each test entry point now calls
t.Setenv(features.VirtualMachinesEnhancedDataModel.EnvVar(), "true")
before checking Enabled(), following an established codebase pattern.

The 3 generated store tests (scan, component, cve) that lacked the
feature flag guard entirely now also have the t.Setenv + skip pattern
for consistency.

Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com

User-facing documentation

Testing and quality

  • the change is production ready: the change is GA, or otherwise the functionality is gated by a feature flag
  • CI results are inspected

Automated testing

  • added unit tests
  • added e2e tests
  • added regression tests
  • added compatibility tests
  • modified existing tests

How I validated my change

This is only about running tests.

@dashrews78
Copy link
Copy Markdown
Contributor Author

dashrews78 commented Mar 30, 2026

@openshift-ci
Copy link
Copy Markdown

openshift-ci bot commented Mar 30, 2026

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@rhacs-bot
Copy link
Copy Markdown
Contributor

rhacs-bot commented Mar 30, 2026

Images are ready for the commit at 7f3b497.

To use with deploy scripts, first export MAIN_IMAGE_TAG=4.11.x-483-g7f3b49703f.

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 49.65%. Comparing base (cc1566a) to head (7f3b497).
⚠️ Report is 5 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #19685      +/-   ##
==========================================
+ Coverage   49.39%   49.65%   +0.25%     
==========================================
  Files        2745     2745              
  Lines      207225   207225              
==========================================
+ Hits       102365   102897     +532     
+ Misses      97268    96677     -591     
- Partials     7592     7651      +59     
Flag Coverage Δ
go-unit-tests 49.65% <ø> (+0.25%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Base automatically changed from dashrews/virt-v2-ensure-33608 to master March 30, 2026 13:25
dashrews78 and others added 2 commits March 30, 2026 10:29
Tests no longer require ROX_VIRTUAL_MACHINES_ENHANCED_DATA_MODEL=true
to be set externally. Each test entry point now calls
t.Setenv(features.VirtualMachinesEnhancedDataModel.EnvVar(), "true")
before checking Enabled(), following an established codebase pattern.

The 3 generated store tests (scan, component, cve) that lacked the
feature flag guard entirely now also have the t.Setenv + skip pattern
for consistency.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The previous commit added t.Setenv to all VM test files, but 3 of them
are auto-generated by pg-bindings generator and must not be manually
edited. This reverts those 3 files to match master, keeping the change
only in the 5 non-generated test files.

Partially generated by AI

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@dashrews78 dashrews78 force-pushed the dashrews/virt-machine-run-tests branch from 3bfa129 to 7f3b497 Compare March 30, 2026 14:34
@dashrews78 dashrews78 marked this pull request as ready for review March 30, 2026 15:48
@dashrews78 dashrews78 merged commit 17c5e25 into master Mar 30, 2026
173 of 195 checks passed
@dashrews78 dashrews78 deleted the dashrews/virt-machine-run-tests branch March 30, 2026 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants