|
| 1 | +# Openshift-virtualization-tests Test plan |
| 2 | + |
| 3 | +## **Scratch Space Storage Class Selection Logic - Quality Engineering Plan** |
| 4 | + |
| 5 | +### **Metadata & Tracking** |
| 6 | + |
| 7 | +- **Enhancement(s):** https://github.com/kubevirt/containerized-data-importer/pull/4054 |
| 8 | +- **Feature Tracking:** https://issues.redhat.com/browse/CNV-72238 |
| 9 | +- **Epic Tracking:** https://issues.redhat.com/browse/CNV-79031 |
| 10 | +- **Feature Maturity:** |
| 11 | + - DP: N/A |
| 12 | + - TP: N/A |
| 13 | + - GA: 4.22 |
| 14 | +- **QE Owner(s):** Kate Shvaika (kshvaika@redhat.com) |
| 15 | +- **Owning SIG:** sig-storage |
| 16 | +- **Participating SIGs:** sig-storage |
| 17 | + |
| 18 | +**Document Conventions (if applicable):** N/A |
| 19 | + |
| 20 | + |
| 21 | +### **Feature Overview** |
| 22 | + |
| 23 | +Some volume provisioning operations (such as registry imports, image uploads, or certain http imports) require an additional temporary PVC known as a scratch space PVC to act as an intermediary step in processing the data prior to writing it to the target PVC. This feature changes the default storage class selection for scratch space PVCs: it now uses the same storage class as the target volume, instead of falling back to the cluster default. Administrators can still configure a specific scratch space storage class to override this behavior by using the CDI config field `scratchSpaceStorageClass` |
| 24 | + |
| 25 | +--- |
| 26 | + |
| 27 | +### **I. Motivation and Requirements Review (QE Review Guidelines)** |
| 28 | + |
| 29 | +This section documents the mandatory QE review process. The goal is to understand the feature's value, |
| 30 | +technology, and testability before formal test planning. |
| 31 | + |
| 32 | +#### **1. Requirement & User Story Review Checklist** |
| 33 | + |
| 34 | +- [x] **Review Requirements** |
| 35 | + - *List the key D/S requirements reviewed:* |
| 36 | + - When no scratch space storage class is configured, scratch space must use the same storage class as the target volume |
| 37 | + - When a scratch space storage class is explicitly configured by the administrator, it must override the default same-as-target behavior |
| 38 | + - Existing administrator configurations for scratch space storage class must continue to work unchanged |
| 39 | + |
| 40 | +- [x] **Understand Value and Customer Use Cases** |
| 41 | + - *Describe the feature's value to customers:* |
| 42 | + - Ensures consistent storage provisioning behavior, reducing confusion and configuration errors |
| 43 | + - Aligns temporary resource allocation with production storage requirements |
| 44 | + - *List the customer use cases identified:* |
| 45 | + - As a VM owner, I want scratch space to use the same storage class as my volume so that provisioning is consistent |
| 46 | + |
| 47 | +- [x] **Testability** |
| 48 | + - *Note any requirements that are unclear or untestable:* None - all requirements are testable through volume provisioning operations (import, upload) with various storage class configurations |
| 49 | + |
| 50 | +- [x] **Acceptance Criteria** |
| 51 | + - *List the acceptance criteria:* |
| 52 | + - When no explicit scratch space storage class is configured, scratch space uses the same storage class as the target PVC |
| 53 | + - When an explicit scratch space storage class is configured, scratch space uses that configured storage class |
| 54 | + - *Note any gaps or missing criteria:* None |
| 55 | + |
| 56 | +- [x] **Non-Functional Requirements (NFRs)** |
| 57 | + - *List applicable NFRs and their targets:* |
| 58 | + - **Documentation:** Documentation update is required to explain new default behavior |
| 59 | + - *Note any NFRs not covered and why:* |
| 60 | + - **UI:** Not applicable. backend storage class selection logic only, no UI changes. |
| 61 | + - **Monitoring:** Not applicable. Existing metrics reflect scratch space creation, no new metrics required |
| 62 | + - **Observability:** Not applicable. Scratch space allocation is logged through existing CDI events |
| 63 | + - **Performance:** Not applicable. No impact on provisioning performance |
| 64 | + - **Security:** Not applicable. Uses existing CDI RBAC for storage operations, no new security requirements. |
| 65 | + - **Scalability:** Not applicable. Selection logic scales with existing CDI controller capabilities |
| 66 | + |
| 67 | + |
| 68 | +#### **2. Known Limitations** |
| 69 | + |
| 70 | +None — reviewed and confirmed with Kate Shvaika, Danny Sanatar / 2026-05-05 that no feature limitations apply for this release. |
| 71 | + |
| 72 | + |
| 73 | +#### **3. Technology and Design Review** |
| 74 | + |
| 75 | +- [x] **Developer Handoff/QE Kickoff** |
| 76 | + - *Key takeaways and concerns:* Reviewed changes in Scratch Space Storage Class Selection Logic with the developer. Untestable aspects were not identified. |
| 77 | + |
| 78 | +- [x] **Technology Challenges** |
| 79 | + - *List identified challenges:* |
| 80 | + - Multiple volume provisioning operations can trigger scratch space allocation (import, upload) |
| 81 | + - *Impact on testing approach:* |
| 82 | + - Tests must cover all volume provisioning operations that use scratch space |
| 83 | + |
| 84 | +- [x] **API Extensions** |
| 85 | + - *List new or modified APIs:* |
| 86 | + - No API changes - internal logic change only |
| 87 | + - Cluster configuration option for scratch space storage class unchanged |
| 88 | + - *Testing impact:* |
| 89 | + - No API testing updates required |
| 90 | + - Functional tests update required |
| 91 | + |
| 92 | +- [x] **Test Environment Needs** |
| 93 | + - *See environment requirements in Section II.3 and testing tools in Section II.3.1* |
| 94 | + - Ability to modify HCO configuration (for scratchSpaceStorageClass override testing) |
| 95 | + |
| 96 | +- [x] **Topology Considerations** |
| 97 | + - *Describe topology requirements:* Standard cluster topology sufficient |
| 98 | + - *Impact on test design:* No special topology requirements |
| 99 | + |
| 100 | +### **II. Software Test Plan (STP)** |
| 101 | + |
| 102 | +This STP serves as the **overall roadmap for testing**, detailing the scope, approach, resources, and schedule. |
| 103 | + |
| 104 | +#### **1. Scope of Testing** |
| 105 | + |
| 106 | +**Testing Goals** |
| 107 | + |
| 108 | +- **[P0]** Verify that volume provisioning operations automatically allocate scratch space using the same storage class as the target volume when no cluster-level override is configured |
| 109 | +- **[P0]** Validate that cluster administrator configuration for scratch space storage class takes priority over the default behavior |
| 110 | +- **[P0]** Confirm consistent scratch space storage class selection across all volume provisioning workflows (import, upload) |
| 111 | + |
| 112 | +**Out of Scope (Testing Scope Exclusions)** |
| 113 | + |
| 114 | +None — reviewed and confirmed that all supported product functionality will be tested this cycle. |
| 115 | +- *Rationale:* Feature changes default storage class selection logic for scratch space only. Scope is narrow and well-defined with clear testable behaviors (default same-as-target vs configured override). All user-facing functionality can be verified through standard disk provisioning operations. |
| 116 | +- *PM/Lead Agreement:* Adam Litke, May 26 2026 |
| 117 | + |
| 118 | + |
| 119 | +**Test Limitations** |
| 120 | + |
| 121 | +None — reviewed and confirmed with Kate Shvaika/2026-05-05 that no test limitations apply for this release. |
| 122 | + |
| 123 | +#### **2. Test Strategy** |
| 124 | + |
| 125 | +**Functional** |
| 126 | + |
| 127 | +- [x] **Functional Testing** — Validates that the feature works according to specified requirements and user stories |
| 128 | + - *Details:* |
| 129 | + - Test new default scratch space SC selection (same-as-target) |
| 130 | + - Test scratchSpaceStorageClass config override behavior |
| 131 | + - Test all CDI operations that allocate scratch space |
| 132 | + - Validate behavior with various storage class configurations |
| 133 | + |
| 134 | +- [x] **Automation Testing** — Confirms test automation plan is in place for CI and regression coverage (all tests are expected to be automated) |
| 135 | + - *Details:* |
| 136 | + - All functional tests will be automated |
| 137 | + |
| 138 | +- [x] **Regression Testing** — Verifies that new changes do not break existing functionality |
| 139 | + - *Details:* |
| 140 | + - Verify existing CDI operations work with new scratch space logic |
| 141 | + - Confirm scratchSpaceStorageClass config continues to work as before (override behavior unchanged) |
| 142 | + |
| 143 | +**Non-Functional** |
| 144 | + |
| 145 | +- [ ] **Performance Testing** — Validates feature performance meets requirements (latency, throughput, resource usage) |
| 146 | + - *Details:* N/A - no impact on provisioning performance |
| 147 | + |
| 148 | +- [ ] **Scale Testing** — Validates feature behavior under increased load and at production-like scale (e.g., large number of VMs, nodes, or concurrent operations) |
| 149 | + - *Details:* N/A - Selection logic scales with existing CDI controller capabilities |
| 150 | + |
| 151 | +- [ ] **Security Testing** — Verifies security requirements, RBAC, authentication, authorization, and vulnerability scanning |
| 152 | + - *Details:* N/A - no new security requirements |
| 153 | + |
| 154 | +- [ ] **Usability Testing** — Validates user experience and accessibility requirements |
| 155 | + - *Details:* N/A - Backend storage class selection logic only |
| 156 | + |
| 157 | +- [ ] **Monitoring** — Does the feature require metrics and/or alerts? |
| 158 | + - *Details:* N/A - no new metrics required |
| 159 | + |
| 160 | + |
| 161 | +**Integration & Compatibility** |
| 162 | + |
| 163 | +- [x] **Compatibility Testing** — Ensures feature works across supported platforms, versions, and configurations |
| 164 | + - Does the feature maintain backward compatibility with previous API versions and configurations? |
| 165 | + - *Details:* Test with different storage class types (OCS, HPP) |
| 166 | + |
| 167 | +- [x] **Upgrade Testing** — Validates upgrade paths from previous versions, data migration, and configuration preservation |
| 168 | + - *Details:* Verify existing scratchSpaceStorageClass configurations are preserved during upgrade. Verify new default behavior (same-as-target) applies to operations started after upgrade. |
| 169 | + |
| 170 | +- [x] **Dependencies** — Blocked by deliverables from other components/products. Identify what we need from other teams before we can test. |
| 171 | + - *Details:* Not applicable. No Dependencies. |
| 172 | + |
| 173 | +- [x] **Cross Integrations** — Does the feature affect other features or require testing by other teams? Identify the impact we cause. |
| 174 | + - *Details:* Not applicable. Changes do not affect other features. |
| 175 | + |
| 176 | + |
| 177 | +**Infrastructure** |
| 178 | + |
| 179 | +- [x] **Cloud Testing** — Does the feature require multi-cloud platform testing? Consider cloud-specific features. |
| 180 | + - *Details:* Not applicable |
| 181 | + |
| 182 | +#### **3. Test Environment** |
| 183 | + |
| 184 | +- **Cluster Topology:** standard 3-master/3-worker |
| 185 | + |
| 186 | +- **OCP & OpenShift Virtualization Version(s):** OCP 4.22 with OpenShift Virtualization 4.22 |
| 187 | + |
| 188 | +- **CPU Virtualization:** VT-x (Intel) or AMD-V enabled |
| 189 | + |
| 190 | +- **Compute Resources:** Minimum per worker node: 8 vCPUs, 32GB RAM |
| 191 | + |
| 192 | +- **Special Hardware:** N/A |
| 193 | + |
| 194 | +- **Storage:** ocs-storagecluster-ceph-rbd-virtualization, hostpath-provisioner, custom SC |
| 195 | + |
| 196 | +- **Network:** OVN-Kubernetes, IPv4 |
| 197 | + |
| 198 | +- **Required Operators:** N/A |
| 199 | + |
| 200 | +- **Platform:** PSI, Bare metal |
| 201 | + |
| 202 | +- **Special Configurations:** N/A |
| 203 | + |
| 204 | +#### **3.1. Testing Tools & Frameworks** |
| 205 | + |
| 206 | +- **Test Framework:** Standard |
| 207 | + |
| 208 | +- **CI/CD:** Standard |
| 209 | + |
| 210 | +- **Other Tools:** N/A |
| 211 | + |
| 212 | +#### **4. Entry Criteria** |
| 213 | + |
| 214 | +The following conditions must be met before testing can begin: |
| 215 | + |
| 216 | +- [x] Requirements and design documents are **approved and merged** |
| 217 | +- [x] CDI implementation of new scratch space selection logic is **complete and merged** |
| 218 | +- [x] Test environment can be **set up and configured** (see Section II.3 - Test Environment) |
| 219 | + |
| 220 | + |
| 221 | +#### **5. Risks** |
| 222 | + |
| 223 | +**Timeline/Schedule** |
| 224 | + |
| 225 | +- **Risk:** N/A |
| 226 | + - **Mitigation:** Standard test timeline is sufficient for planned test scenarios. Feature scope is narrow with straightforward test cases. |
| 227 | + - *Estimated impact on schedule:* None |
| 228 | + - *Sign-off:* Kate Shvaika/2026-05-05 |
| 229 | + |
| 230 | +**Test Coverage** |
| 231 | + |
| 232 | +- **Risk:** N/A |
| 233 | + - **Mitigation:** All acceptance criteria are covered by planned test scenarios. |
| 234 | + - *Areas with reduced coverage:* None |
| 235 | + - *Sign-off:* Kate Shvaika/2026-05-05 |
| 236 | + |
| 237 | +**Test Environment** |
| 238 | + |
| 239 | +- **Risk:** N/A |
| 240 | + - **Mitigation:** Standard test environment with multiple storage classes is sufficient for testing this feature |
| 241 | + - *Missing resources or infrastructure:* None |
| 242 | + - *Sign-off:* Kate Shvaika/2026-05-05 |
| 243 | + |
| 244 | +**Untestable Aspects** |
| 245 | + |
| 246 | +- **Risk:** N/A |
| 247 | + - **Mitigation:** All scenarios can be reproduced in test environment |
| 248 | + - *Alternative validation approach:* None |
| 249 | + - *Sign-off:* Kate Shvaika/2026-05-05 |
| 250 | + |
| 251 | +**Resource Constraints** |
| 252 | + |
| 253 | +- **Risk:** N/A |
| 254 | + - **Mitigation:** Current QE team capacity is sufficient for planned test execution |
| 255 | + - *Current capacity gaps:* None |
| 256 | + - *Sign-off:* Kate Shvaika/2026-05-05 |
| 257 | + |
| 258 | +**Dependencies** |
| 259 | + |
| 260 | +- **Risk:** N/A |
| 261 | + - **Mitigation:** No external dependencies. |
| 262 | + - *Dependent teams or components:* Documentation team for behavior change documentation (non-blocking) |
| 263 | + - *Sign-off:* Kate Shvaika/2026-05-05 |
| 264 | + |
| 265 | +**Other** |
| 266 | + |
| 267 | +- **Risk:** N/A |
| 268 | + - **Mitigation:** No additional mitigation required |
| 269 | + - *Sign-off:* Kate Shvaika/2026-05-05 |
| 270 | + |
| 271 | +--- |
| 272 | + |
| 273 | +### **III. Test Scenarios & Traceability** |
| 274 | + |
| 275 | +- **[CNV-72238]** — As a user, I want import operations to use the same storage class for scratch space as my target DataVolume |
| 276 | + - *Test Scenario:* [Tier 2] Verify import requiring conversion allocates scratch space using target DataVolume storage class |
| 277 | + - *Priority:* P0 |
| 278 | + |
| 279 | +- **[CNV-72238]** — As a user, I want upload operations to use the same storage class for scratch space as my target DataVolume |
| 280 | + - *Test Scenario:* [Tier 2] Verify upload operation allocates scratch space using target DataVolume storage class |
| 281 | + - *Priority:* P0 |
| 282 | + |
| 283 | +- **[CNV-72238]** — As a cluster admin, I want scratchSpaceStorageClass configuration to propagate from HCO to CDI |
| 284 | + - *Test Scenario:* [Tier 2] Verify scratchSpaceStorageClass set in HCO CR propagates to CDI CR configuration |
| 285 | + - *Priority:* P0 |
| 286 | + |
| 287 | +- **[CNV-72238]** — As a cluster admin, I want to configure scratch space storage class for import operations |
| 288 | + - *Test Scenario:* [Tier 2] Verify import operation uses scratchSpaceStorageClass configured in HCO |
| 289 | + - *Priority:* P0 |
| 290 | + |
| 291 | +--- |
| 292 | + |
| 293 | +### **IV. Sign-off and Approval** |
| 294 | + |
| 295 | +This Software Test Plan requires approval from the following stakeholders: |
| 296 | + |
| 297 | +* **Reviewers:** |
| 298 | + - QE Architect: Ruth Netser (@rnetser) |
| 299 | + - QE Members (OCP-V): Jenia Peimer (@jpeimer), Jose Manuel Castano (@joscasta) |
| 300 | + - Developer: Danny Sanatar (@dsanatar) |
| 301 | +* **Approvers:** |
| 302 | + - QE Architect: Ruth Netser (@rnetser) |
| 303 | + - QE Lead: Jenia Peimer (@jpeimer) |
0 commit comments