Skip to content

Conversation

@OhadRevah
Copy link
Contributor

@OhadRevah OhadRevah commented Nov 18, 2025

Short description:

The metric kubevirt_vmi_migration_disk_transfer_rate_bytes renamed, this PR refactoring the old metric name to the new one.

More details:
What this PR does / why we need it:
Which issue(s) this PR fixes:
Special notes for reviewer:
jira-ticket:

https://issues.redhat.com/browse/CNV-55919

Summary by CodeRabbit

  • Tests
    • Updated VM migration observability tests to reference and validate memory transfer rate measurements (replacing the previous disk transfer rate target), ensuring metrics reflect memory transfer behavior.

✏️ Tip: You can customize this high-level summary in your review settings.

The metric kubevirt_vmi_migration_disk_transfer_rate_bytes renamed,
this PR refactoring the old metric name to the new one.
@coderabbitai
Copy link

coderabbitai bot commented Nov 18, 2025

Walkthrough

Renames a test constant from KUBEVIRT_VMI_MIGRATION_DISK_TRANSFER_RATE_BYTES to KUBEVIRT_VMI_MIGRATION_MEMORY_TRANSFER_RATE_BYTES and updates its usages in test files to reference the memory-transfer metric instead of disk-transfer.

Changes

Cohort / File(s) Change Summary
Migration metrics constant + tests
tests/observability/metrics/constants.py, tests/observability/metrics/test_migration_metrics.py
Renamed exported constant KUBEVIRT_VMI_MIGRATION_DISK_TRANSFER_RATE_BYTESKUBEVIRT_VMI_MIGRATION_MEMORY_TRANSFER_RATE_BYTES. Updated import and test parameterization to use the renamed constant; adjusted constant value to reference the memory transfer metric (template preserved).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

  • Verify the constant rename is applied consistently across both files.
  • Confirm the metric referenced in the constant value is the intended memory-transfer metric.
  • Search for any remaining references to the old constant name.

Suggested labels

can-be-merged, commented-coderabbitai[bot]

Suggested reviewers

  • rnetser
  • RoniKishner
  • dshchedr
  • vsibirsk
  • rlobillo
  • hmeir

Pre-merge checks and finishing touches

❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Description check ❓ Inconclusive The PR description includes a short description and a Jira ticket reference, but is missing detailed explanations of what the PR does, why it's needed, and which issues it fixes. Complete the description by filling in 'What this PR does / why we need it' and 'Which issue(s) this PR fixes' sections for better clarity and context.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: renaming a metric constant from disk transfer rate to memory transfer rate, which aligns with the actual refactoring in the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9bcd2e1 and 2e7bb85.

📒 Files selected for processing (1)
  • tests/observability/metrics/constants.py (1 hunks)
🧰 Additional context used
🧠 Learnings (11)
📓 Common learnings
Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 2469
File: utilities/sanity.py:139-142
Timestamp: 2025-11-08T07:36:57.616Z
Learning: In the openshift-virtualization-tests repository, user rnetser prefers to keep refactoring PRs (like PR #2469) strictly focused on moving/organizing code into more granular modules without adding new functionality, error handling, or behavioral changes. Such improvements should be handled in separate PRs.
Learnt from: dshchedr
Repo: RedHatQE/openshift-virtualization-tests PR: 1716
File: tests/virt/node/workload_density/test_swap.py:120-124
Timestamp: 2025-08-09T01:47:21.485Z
Learning: In the openshift-virtualization-tests repository, float values for VM memory specifications (like those passed to VirtualMachineForTests memory parameters) are automatically converted to integers by webhooks, so explicit int conversion is not required when calculating memory sizes.
Learnt from: akri3i
Repo: RedHatQE/openshift-virtualization-tests PR: 1210
File: tests/virt/cluster/general/mass_machine_type_transition_tests/conftest.py:142-149
Timestamp: 2025-06-23T19:18:12.275Z
Learning: In OpenShift Virtualization machine type transition tests, the kubevirt_api_lifecycle_automation_job updates VM machine types to the latest version based on a MACHINE_TYPE_GLOB pattern, and subsequent fixtures may intentionally revert the machine type to test bidirectional transition behavior.
📚 Learning: 2025-08-09T01:47:21.485Z
Learnt from: dshchedr
Repo: RedHatQE/openshift-virtualization-tests PR: 1716
File: tests/virt/node/workload_density/test_swap.py:120-124
Timestamp: 2025-08-09T01:47:21.485Z
Learning: In the openshift-virtualization-tests repository, float values for VM memory specifications (like those passed to VirtualMachineForTests memory parameters) are automatically converted to integers by webhooks, so explicit int conversion is not required when calculating memory sizes.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-09-29T19:05:24.987Z
Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 0
File: :0-0
Timestamp: 2025-09-29T19:05:24.987Z
Learning: For PR #1904 test execution, the critical validation point is test_connectivity_over_migration_between_localnet_vms which should fail gracefully on cloud clusters but pass on bare-metal/PSI clusters, representing the core nmstate conditional logic functionality.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-06-18T09:15:25.436Z
Learnt from: OhadRevah
Repo: RedHatQE/openshift-virtualization-tests PR: 1166
File: tests/observability/metrics/conftest.py:1178-1180
Timestamp: 2025-06-18T09:15:25.436Z
Learning: In tests/observability/metrics/conftest.py, the `stopped_vm_metric_1` fixture is intentionally designed to stop the VM and leave it in that state - it does not need to restart the VM afterward as this is the desired behavior for the tests that use it.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-06-10T11:41:36.366Z
Learnt from: OhadRevah
Repo: RedHatQE/openshift-virtualization-tests PR: 1172
File: tests/observability/metrics/test_migration_metrics.py:36-41
Timestamp: 2025-06-10T11:41:36.366Z
Learning: For transient migration metrics like KUBEVIRT_VMI_MIGRATIONS_IN_SCHEDULING_PHASE and KUBEVIRT_VMI_MIGRATIONS_IN_RUNNING_PHASE in OpenShift Virtualization tests, use check_times=1 with wait_for_expected_metric_value_sum() to capture the metric value immediately without requiring multiple consecutive matches, as these metrics are raised for very short periods and may decrease while checking again.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-06-23T19:18:12.275Z
Learnt from: akri3i
Repo: RedHatQE/openshift-virtualization-tests PR: 1210
File: tests/virt/cluster/general/mass_machine_type_transition_tests/conftest.py:142-149
Timestamp: 2025-06-23T19:18:12.275Z
Learning: In OpenShift Virtualization machine type transition tests, the kubevirt_api_lifecycle_automation_job updates VM machine types to the latest version based on a MACHINE_TYPE_GLOB pattern, and subsequent fixtures may intentionally revert the machine type to test bidirectional transition behavior.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-06-23T19:24:28.327Z
Learnt from: akri3i
Repo: RedHatQE/openshift-virtualization-tests PR: 1210
File: tests/virt/cluster/general/mass_machine_type_transition_tests/test_mass_machine_type_transition.py:97-104
Timestamp: 2025-06-23T19:24:28.327Z
Learning: In OpenShift Virtualization machine type transition tests, the test_machine_type_transition_without_restart method with restart_required=false parameter validates that VM machine types do NOT change when the lifecycle job runs with restart disabled, so the assertion should check against the original machine type rather than the target machine type.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-09-29T20:33:51.007Z
Learnt from: dshchedr
Repo: RedHatQE/openshift-virtualization-tests PR: 1932
File: tests/virt/node/migration_and_maintenance/conftest.py:65-72
Timestamp: 2025-09-29T20:33:51.007Z
Learning: In tests/virt/node/migration_and_maintenance/conftest.py, the added_vm_cpu_limit fixture doesn't require ResourceEditor as a context manager because it's the final test to modify the vm_for_multifd_test VM before teardown, so restoration of CPU limits is unnecessary overhead as confirmed by maintainer dshchedr.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-08-04T15:27:14.175Z
Learnt from: OhadRevah
Repo: RedHatQE/openshift-virtualization-tests PR: 1166
File: tests/observability/metrics/conftest.py:1065-1082
Timestamp: 2025-08-04T15:27:14.175Z
Learning: In tests/observability/metrics/conftest.py, the `non_existent_node_windows_vm` fixture is used for tier3 Windows VM testing and must use Windows VMs rather than Linux VMs, even though it adds overhead, because it's specifically testing Windows VM status transition metrics as part of dedicated Windows VM test coverage.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-09-29T19:05:24.987Z
Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 0
File: :0-0
Timestamp: 2025-09-29T19:05:24.987Z
Learning: The test execution plan for PR #1904 focuses on cluster-type conditional logic where nmstate functionality is bypassed on cloud clusters (Azure/AWS) but fully functional on bare-metal/PSI clusters, requiring different test strategies for each environment type.

Applied to files:

  • tests/observability/metrics/constants.py
📚 Learning: 2025-09-08T21:34:28.924Z
Learnt from: dshchedr
Repo: RedHatQE/openshift-virtualization-tests PR: 1932
File: tests/virt/node/migration_and_maintenance/conftest.py:57-64
Timestamp: 2025-09-08T21:34:28.924Z
Learning: In OpenShift Virtualization tests, MigrationPolicy fixtures should use static names rather than unique suffixes to enable collision detection. If parallel test runs collide on cluster-scoped resource names like MigrationPolicy, it's better to know about the collision rather than hide it with unique naming, as confirmed by maintainer dshchedr.

Applied to files:

  • tests/observability/metrics/constants.py
🔇 Additional comments (1)
tests/observability/metrics/constants.py (1)

20-22: Approved. All references to the old constant have been updated, and the new metric name is verified correct.

Verification confirmed:

  • The metric rename from kubevirt_vmi_migration_disk_transfer_rate_bytes to kubevirt_vmi_migration_memory_transfer_rate_bytes aligns with KubeVirt PR #13500
  • No stale references to the old constant remain in the codebase
  • The new constant is properly imported and used in test files

Tip

📝 Customizable high-level summaries are now available in beta!

You can now customize how CodeRabbit generates the high-level summary in your pull requests — including its content, structure, tone, and formatting.

  • Provide your own instructions using the high_level_summary_instructions setting.
  • Format the summary however you like (bullet lists, tables, multi-section layouts, contributor stats, etc.).
  • Use high_level_summary_in_walkthrough to move the summary from the description to the walkthrough section.

Example instruction:

"Divide the high-level summary into five sections:

  1. 📝 Description — Summarize the main change in 50–60 words, explaining what was done.
  2. 📓 References — List relevant issues, discussions, documentation, or related PRs.
  3. 📦 Dependencies & Requirements — Mention any new/updated dependencies, environment variable changes, or configuration updates.
  4. 📊 Contributor Summary — Include a Markdown table showing contributions:
    | Contributor | Lines Added | Lines Removed | Files Changed |
  5. ✔️ Additional Notes — Add any extra reviewer context.
    Keep each section concise (under 200 words) and use bullet or numbered lists for clarity."

Note: This feature is currently in beta for Pro-tier users, and pricing will be announced later.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-virtualization-qe-bot

Report bugs in Issues

Welcome! 🎉

This pull request will be automatically processed with the following features:

🔄 Automatic Actions

  • Reviewer Assignment: Reviewers are automatically assigned based on the "
    "OWNERS file in the repository root
    "
    "* Size Labeling: PR size labels (XS, S, M, L, XL, XXL) are "
    "automatically applied based on changes
    "
    f"* Issue Creation: A tracking issue is created for this PR and will be closed when the PR is merged or closed
    "
    "* Pre-commit Checks: pre-commit runs "
    "automatically if .pre-commit-config.yaml exists
    "
  • Branch Labeling: Branch-specific labels are applied to track the target branch
  • Auto-verification: Auto-verified users have their PRs automatically marked as verified

📋 Available Commands

PR Status Management

  • /wip - Mark PR as work in progress (adds WIP: prefix to title)
  • /wip cancel - Remove work in progress status
  • /hold - Block PR merging (approvers only)
  • /hold cancel - Unblock PR merging
  • /verified - Mark PR as verified
  • /verified cancel - Remove verification status
  • /reprocess - Trigger complete PR workflow reprocessing (useful if webhook failed or configuration changed)

Review & Approval

  • /lgtm - Approve changes (looks good to me)
  • /approve - Approve PR (approvers only)
  • /automerge - Enable automatic merging when all requirements are met (maintainers and approvers only)
  • /assign-reviewers - Assign reviewers based on OWNERS file
  • /assign-reviewer @username - Assign specific reviewer
  • /check-can-merge - Check if PR meets merge requirements

Testing & Validation

  • /retest tox - Run Python test suite with tox
  • /retest build-container - Rebuild and test container image
  • /retest all - Run all available tests

Container Operations

  • /build-and-push-container - Build and push container image (tagged with PR number)
    • Supports additional build arguments: /build-and-push-container --build-arg KEY=value

Cherry-pick Operations

  • /cherry-pick <branch> - Schedule cherry-pick to target branch when PR is merged
    • Multiple branches: /cherry-pick branch1 branch2 branch3

Label Management

  • /<label-name> - Add a label to the PR
  • /<label-name> cancel - Remove a label from the PR

✅ Merge Requirements

This PR will be automatically approved when the following conditions are met:

  1. Approval: /approve from at least one approver
  2. LGTM Count: Minimum 2 /lgtm from reviewers
  3. Status Checks: All required status checks must pass
  4. No Blockers: No WIP, hold, or conflict labels
  5. Verified: PR must be marked as verified (if verification is enabled)

📊 Review Process

Approvers and Reviewers

Approvers:

  • dshchedr
  • myakove
  • rnetser
  • vsibirsk

Reviewers:

  • OhadRevah
  • RoniKishner
  • albarker-rh
  • dshchedr
  • hmeir
  • rlobillo
  • rnetser
  • vsibirsk
Available Labels
  • hold
  • verified
  • wip
  • lgtm
  • approve
  • automerge

💡 Tips

  • WIP Status: Use /wip when your PR is not ready for review
  • Verification: The verified label is automatically removed on each new commit
  • Cherry-picking: Cherry-pick labels are processed when the PR is merged
  • Container Builds: Container images are automatically tagged with the PR number
  • Permission Levels: Some commands require approver permissions
  • Auto-verified Users: Certain users have automatic verification and merge privileges

For more information, please refer to the project documentation or contact the maintainers.

@openshift-virtualization-qe-bot

albarker-rh can not be added as reviewer. Reviews may only be requested from collaborators. One or more of the users or teams you specified is not a collaborator of the RedHatQE/openshift-virtualization-tests repository.: 422 {"message": "Reviews may only be requested from collaborators. One or more of the users or teams you specified is not a collaborator of the RedHatQE/openshift-virtualization-tests repository.", "documentation_url": "https://docs.github.com/rest/pulls/review-requests#request-reviewers-for-a-pull-request", "status": "422"}

@OhadRevah
Copy link
Contributor Author

/verified

@openshift-virtualization-qe-bot-3
Copy link
Contributor

@coderabbitai

Test execution plan request details

CRITICAL: You MUST respond with a review comment on the Files Changed tab, NOT as a regular PR comment.
If it cannot be on the 1st line of the 1st file, add it to any other changed file.

As an expert software testing engineer, analyze all modified files in this PR and create a targeted test execution plan.
You will create a change request comment on the 1st line of the 1st file in the pr with the test execution plan.
If you fail to run or post a comment, retry.

Analysis Requirements:

  1. Examine code changes in each modified file
  2. Identify affected code paths, functions, and classes
  3. Analyze pytest-specific elements: fixtures (scope, dependencies), parametrization, markers, conftest changes
  4. Trace test dependencies through imports, shared utilities, and fixture inheritance
  5. Detect new tests introduced in the PR

Your deliverable:
Your change request comment will be based on the following requirements:

Test Execution Plan

  • path/to/test_file.py - When the entire test file needs verification
  • path/to/test_file.py::TestClass::test_method - When specific test(s) needed
  • path/to/test_file.py::test_function - When specific test(s) needed
  • -m marker - When specific marker(s) can be used to cover multiple cases.

Guidelines:

  • Include only tests directly affected by the changes
  • Use a full file path only if ALL tests in that file require verification
  • Use file path + test name if only specific tests are needed
  • If a test marker can cover multiple files/tests, provide the marker
  • Balance coverage vs over-testing - Keep descriptions minimal
  • Do not add a follow-up comment in the PR, only the change request one

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Test Execution Plan

Affected Test:

  • tests/observability/metrics/test_migration_metrics.py::TestKubevirtVmiMigrationMetrics::test_kubevirt_vmi_migration_metrics

Rationale:
This PR renames the metric constant from KUBEVIRT_VMI_MIGRATION_DISK_TRANSFER_RATE_BYTES to KUBEVIRT_VMI_MIGRATION_MEMORY_TRANSFER_RATE_BYTES. The parametrized test uses this constant (specifically the test case marked with Polarion CNV-11598) and will verify:

  1. The renamed constant is correctly imported
  2. The new metric name is properly queried from Prometheus
  3. Migration metrics validation continues to work correctly

Test Coverage:
Running this single parametrized test case is sufficient as it directly validates the renamed metric constant in the context of VM migration monitoring.

@coderabbitai
Copy link

coderabbitai bot commented Nov 24, 2025

Tip

For best results, initiate chat on the files or code changes.

🧩 Analysis chain

@openshift-virtualization-qe-bot-3, I'll post the test execution plan as a review comment on the Files Changed tab.


🏁 Script executed:

#!/bin/bash

# Attempt to post a review comment on the first changed file
gh api \
  --method POST \
  -H "Accept: application/vnd.github+json" \
  -H "X-GitHub-Api-Version: 2022-11-28" \
  /repos/RedHatQE/openshift-virtualization-tests/pulls/2708/reviews \
  -f event='COMMENT' \
  -f body='## Test Execution Plan

**Affected Test:**
- `tests/observability/metrics/test_migration_metrics.py::TestKubevirtVmiMigrationMetrics::test_kubevirt_vmi_migration_metrics`

**Rationale:**
This PR renames the metric constant from `KUBEVIRT_VMI_MIGRATION_DISK_TRANSFER_RATE_BYTES` to `KUBEVIRT_VMI_MIGRATION_MEMORY_TRANSFER_RATE_BYTES`. The parametrized test uses this constant (Polarion CNV-11598) and will verify:
1. The renamed constant is correctly imported
2. The new metric name is properly queried from Prometheus
3. Migration metrics validation continues to work correctly' \
  -f 'comments[][path]=tests/observability/metrics/constants.py' \
  -f 'comments[][body]=## Test Execution Plan

**Affected Test:**
- `tests/observability/metrics/test_migration_metrics.py::TestKubevirtVmiMigrationMetrics::test_kubevirt_vmi_migration_metrics`' \
  -F 'comments[][line]=1'

echo ""
echo "Review comment posted successfully"

Length of output: 346


@openshift-virtualization-qe-bot-3, let me try a different approach to post the review comment.


🏁 Script executed:

#!/bin/bash

# First, let's get the diff to understand the structure
gh pr diff 2708 --repo RedHatQE/openshift-virtualization-tests | head -50

Length of output: 2171


🏁 Script executed:

#!/bin/bash

# Post a general PR review comment without line-specific attachment
gh api \
  --method POST \
  -H "Accept: application/vnd.github+json" \
  -H "X-GitHub-Api-Version: 2022-11-28" \
  /repos/RedHatQE/openshift-virtualization-tests/pulls/2708/reviews \
  -f event='COMMENT' \
  -f body='## Test Execution Plan

**Affected Test:**
- `tests/observability/metrics/test_migration_metrics.py::TestKubevirtVmiMigrationMetrics::test_kubevirt_vmi_migration_metrics`

**Rationale:**
This PR renames the metric constant from `KUBEVIRT_VMI_MIGRATION_DISK_TRANSFER_RATE_BYTES` to `KUBEVIRT_VMI_MIGRATION_MEMORY_TRANSFER_RATE_BYTES`. The parametrized test uses this constant (specifically the test case marked with Polarion CNV-11598) and will verify:
1. The renamed constant is correctly imported
2. The new metric name is properly queried from Prometheus
3. Migration metrics validation continues to work correctly

**Test Coverage:**
Running this single parametrized test case is sufficient as it directly validates the renamed metric constant in the context of VM migration monitoring.'

echo ""
echo "✓ Review comment posted successfully"

Length of output: 2566


@openshift-virtualization-qe-bot-3, I've successfully posted the test execution plan as a review comment on PR #2708.

The review comment includes:

Test Execution Plan

Affected Test:

  • tests/observability/metrics/test_migration_metrics.py::TestKubevirtVmiMigrationMetrics::test_kubevirt_vmi_migration_metrics

Rationale:
This PR renames the metric constant from KUBEVIRT_VMI_MIGRATION_DISK_TRANSFER_RATE_BYTES to KUBEVIRT_VMI_MIGRATION_MEMORY_TRANSFER_RATE_BYTES. The parametrized test uses this constant (specifically the test case marked with Polarion CNV-11598) and will verify:

  1. The renamed constant is correctly imported
  2. The new metric name is properly queried from Prometheus
  3. Migration metrics validation continues to work correctly

The review comment is now visible on the PR and can be viewed at: #2708 (review)


🧠 Learnings used
Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 2469
File: utilities/sanity.py:139-142
Timestamp: 2025-11-08T07:36:57.616Z
Learning: In the openshift-virtualization-tests repository, user rnetser prefers to keep refactoring PRs (like PR #2469) strictly focused on moving/organizing code into more granular modules without adding new functionality, error handling, or behavioral changes. Such improvements should be handled in separate PRs.

Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 0
File: :0-0
Timestamp: 2025-09-29T19:05:24.987Z
Learning: The test execution plan for PR #1904 focuses on cluster-type conditional logic where nmstate functionality is bypassed on cloud clusters (Azure/AWS) but fully functional on bare-metal/PSI clusters, requiring different test strategies for each environment type.

Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 0
File: :0-0
Timestamp: 2025-09-29T19:05:24.987Z
Learning: For PR #1904 test execution, the critical validation point is test_connectivity_over_migration_between_localnet_vms which should fail gracefully on cloud clusters but pass on bare-metal/PSI clusters, representing the core nmstate conditional logic functionality.

Learnt from: vsibirsk
Repo: RedHatQE/openshift-virtualization-tests PR: 2045
File: tests/virt/cluster/vm_lifecycle/conftest.py:46-47
Timestamp: 2025-09-15T06:49:53.478Z
Learning: In the openshift-virtualization-tests repo, large fixture refactoring efforts like the golden image data source migration are handled incrementally by directory/team ownership. The virt/cluster directory is handled separately from virt/node, tests/infra, tests/storage, etc., with each area managed by relevant teams in follow-up PRs.

Learnt from: dshchedr
Repo: RedHatQE/openshift-virtualization-tests PR: 1716
File: tests/virt/conftest.py:289-297
Timestamp: 2025-08-09T01:52:26.683Z
Learning: When user dshchedr moves working code from one location to another in the openshift-virtualization-tests repository, they prefer not to modify it unless there's a real issue, maintaining the original implementation to avoid introducing unnecessary changes.

Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 1236
File: conftest.py:539-557
Timestamp: 2025-06-18T13:26:04.504Z
Learning: In the openshift-virtualization-tests repository, PR #1236 intentionally limits error extraction to the setup phase only in the pytest_runtest_makereport hook. The scope is deliberately restricted to setup failures, not all test phases.

Learnt from: dshchedr
Repo: RedHatQE/openshift-virtualization-tests PR: 1932
File: tests/virt/node/migration_and_maintenance/conftest.py:57-64
Timestamp: 2025-09-08T21:34:28.924Z
Learning: In OpenShift Virtualization tests, MigrationPolicy fixtures should use static names rather than unique suffixes to enable collision detection. If parallel test runs collide on cluster-scoped resource names like MigrationPolicy, it's better to know about the collision rather than hide it with unique naming, as confirmed by maintainer dshchedr.

Learnt from: vamsikrishna-siddu
Repo: RedHatQE/openshift-virtualization-tests PR: 2199
File: tests/storage/test_online_resize.py:108-113
Timestamp: 2025-09-28T14:43:07.181Z
Learning: In the openshift-virtualization-tests repo, PR #2199 depends on PR #2139 which adds architecture-specific OS_FLAVOR attributes to the Images.Cirros class (OS_FLAVOR_CIRROS for x86_64/ARM64, OS_FLAVOR_FEDORA for s390x), enabling conditional logic based on the underlying OS flavor in tests.

Learnt from: rlobillo
Repo: RedHatQE/openshift-virtualization-tests PR: 1984
File: tests/install_upgrade_operators/network_policy/test_network_policy_components.py:182-187
Timestamp: 2025-09-12T14:14:28.329Z
Learning: Network policy tests in the RedHatQE/openshift-virtualization-tests repository don't require unique resource names as there are no parallel runs on the same cluster in their test environment.

Learnt from: vamsikrishna-siddu
Repo: RedHatQE/openshift-virtualization-tests PR: 2199
File: tests/storage/test_online_resize.py:108-113
Timestamp: 2025-09-28T14:43:07.181Z
Learning: In the openshift-virtualization-tests repo, PR #2199 depends on PR #2139 which adds the OS_FLAVOR attribute to the Images.Cirros class, making Images.Cirros.OS_FLAVOR available for conditional logic in tests.

Learnt from: rnetser
Repo: RedHatQE/openshift-virtualization-tests PR: 1028
File: utilities/infra.py:1249-1254
Timestamp: 2025-08-06T13:57:51.928Z
Learning: User rnetser verified that all calls to get_infrastructure() function use the admin_client parameter, confirming that signature changes requiring this parameter don't cause breaking changes in the openshift-virtualization-tests codebase.

Learnt from: servolkov
Repo: RedHatQE/openshift-virtualization-tests PR: 1776
File: libs/net/node_network.py:25-31
Timestamp: 2025-08-20T23:43:28.117Z
Learning: In the RedHatQE/openshift-virtualization-tests project, servolkov's team always uses bare metal (BM) clusters with IPv4 setup in their testing environment, making defensive checks for IPv4 data presence potentially redundant in their networking code.

Learnt from: jpeimer
Repo: RedHatQE/openshift-virtualization-tests PR: 1160
File: tests/storage/storage_migration/test_mtc_storage_class_migration.py:165-176
Timestamp: 2025-06-17T07:45:37.776Z
Learning: In the openshift-virtualization-tests repository, user jpeimer prefers explicit fixture parameters over composite fixtures in test methods, even when there are many parameters, as they find this approach more readable and maintainable for understanding test dependencies.

Learnt from: akri3i
Repo: RedHatQE/openshift-virtualization-tests PR: 1210
File: tests/virt/cluster/general/mass_machine_type_transition_tests/conftest.py:24-64
Timestamp: 2025-06-23T19:28:20.281Z
Learning: In OpenShift Virtualization mass machine type transition tests, the machine type glob pattern "pc-q35-rhel8.*.*" is intentionally hard-coded in the kubevirt_api_lifecycle_automation_job as it's used only once for this specific test case, with plans to update it in the future if the job needs to support other machine types.

Learnt from: RoniKishner
Repo: RedHatQE/openshift-virtualization-tests PR: 1411
File: utilities/os_utils.py:246-279
Timestamp: 2025-07-22T17:13:59.166Z
Learning: In the RedHatQE/openshift-virtualization-tests repository, CentOS preferences follow the format "centos-stream<version>" (e.g., "centos-stream9", "centos-stream10"). The generate_instance_type_centos_os_matrix function correctly uses regex to extract numeric versions and constructs the latest version string in the same format as the input preferences for proper comparison.

Learnt from: akri3i
Repo: RedHatQE/openshift-virtualization-tests PR: 1210
File: tests/virt/cluster/general/mass_machine_type_transition_tests/conftest.py:83-97
Timestamp: 2025-06-23T19:19:31.961Z
Learning: In OpenShift Virtualization mass machine type transition tests, the kubevirt_api_lifecycle_automation_job requires cluster-admin privileges to function properly, as confirmed by the test maintainer akri3i.

Learnt from: SiboWang1997
Repo: RedHatQE/openshift-virtualization-tests PR: 1566
File: tests/global_config_x86_64.py:29-29
Timestamp: 2025-07-25T01:59:02.180Z
Learning: In the openshift-virtualization-tests repo, the s390x architecture still relies on Fedora 41 images, while only x86_64 is updated to Fedora 42 in PR #1566.

@rnetser
Copy link
Collaborator

rnetser commented Nov 24, 2025

/approve
/lgtm

@rnetser rnetser merged commit 25b9106 into RedHatQE:main Nov 24, 2025
20 checks passed
@openshift-virtualization-qe-bot-3
Copy link
Contributor

New container for quay.io/openshift-cnv/openshift-virtualization-tests:latest published

@OhadRevah OhadRevah deleted the rename_disk_transfer_rate_bytes_metric branch November 25, 2025 08:28
@OhadRevah
Copy link
Contributor Author

/cherry-pick cnv-4.20

openshift-virtualization-qe-bot-3 pushed a commit that referenced this pull request Nov 25, 2025
##### Short description:
The metric kubevirt_vmi_migration_disk_transfer_rate_bytes renamed, this
PR refactoring the old metric name to the new one.

##### More details:

##### What this PR does / why we need it:

##### Which issue(s) this PR fixes:

##### Special notes for reviewer:

##### jira-ticket:
https://issues.redhat.com/browse/CNV-55919


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Tests**
* Updated VM migration observability tests to reference and validate
memory transfer rate measurements (replacing the previous disk transfer
rate target), ensuring metrics reflect memory transfer behavior.

<sub>✏️ Tip: You can customize this high-level summary in your review
settings.</sub>
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
@openshift-virtualization-qe-bot-3
Copy link
Contributor

Cherry-picked PR Rename kubevirt_vmi_migration_disk_transfer_rate_bytes metric into cnv-4.20

openshift-virtualization-qe-bot-3 added a commit that referenced this pull request Nov 27, 2025
…rate_bytes metric (#2843)

cherry-pick
#2708
into cnv-4.20

requested-by OhadRevah

Co-authored-by: Ohad Revah <orevah@redhat.com>
openshift-virtualization-qe-bot-3 added a commit that referenced this pull request Nov 27, 2025
…rate_bytes metric (#2843)

cherry-pick
#2708
into cnv-4.20

requested-by OhadRevah

Co-authored-by: Ohad Revah <orevah@redhat.com>
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.

8 participants