Stabilize reconciler unit tests to fix Run Unit Tests GitHub Actions failure#11772
Stabilize reconciler unit tests to fix Run Unit Tests GitHub Actions failure#11772Copilot wants to merge 20 commits into
Conversation
…icep, warn on existing config Agent-Logs-Url: https://github.com/radius-project/radius/sessions/501b2ffa-3885-4125-99fc-75725464c1c1 Co-authored-by: zachcasper <30731731+zachcasper@users.noreply.github.com>
Agent-Logs-Url: https://github.com/radius-project/radius/sessions/501b2ffa-3885-4125-99fc-75725464c1c1 Co-authored-by: zachcasper <30731731+zachcasper@users.noreply.github.com>
Agent-Logs-Url: https://github.com/radius-project/radius/sessions/9a66910e-d878-4ed9-b3c8-0d0e2e946229 Co-authored-by: zachcasper <30731731+zachcasper@users.noreply.github.com>
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
Unit Tests 1 files - 1 336 suites - 87 7m 22s ⏱️ -17s For more details on these failures, see this check. Results for commit ca279b7. ± Comparison against base commit 9a15c2d. This pull request removes 25 and adds 10 tests. Note that renamed tests count towards both.♻️ This comment has been updated with latest results. |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #11772 +/- ##
==========================================
+ Coverage 51.39% 51.42% +0.03%
==========================================
Files 716 713 -3
Lines 45106 45025 -81
==========================================
- Hits 23181 23156 -25
+ Misses 19725 19678 -47
+ Partials 2200 2191 -9 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Signed-off-by: Zach Casper <zachcasper@microsoft.com>
…splay Agent-Logs-Url: https://github.com/radius-project/radius/sessions/23a78e3b-db8f-4d7c-a3aa-4a3cd5ffd8d6 Co-authored-by: zachcasper <30731731+zachcasper@users.noreply.github.com>
Resolve conflicts after the rad init refactor on main that moved shared prompt and display logic into pkg/cli/cmd/radinit/common. - application.go/application_test.go: keep PR's deletion (rad init no longer prompts to scaffold an application). - display.go: keep PR's BicepConfig rename. Switch to the thin wrapper introduced on main and pass the bicepconfig file through a new common.BicepConfigDisplay so the shared summary/progress views render the '🚧 Create bicepconfig.json' step. - common/display.go: add BicepConfigDisplay, BicepConfigComplete, and the bicepconfig summary/progress rendering. Make isComplete only require ApplicationComplete when scaffolding and BicepConfigComplete when bicepconfig files are present, so both rad init and rad init --preview work. - pkg/cli/setup/application.go: restore ScaffoldApplication so rad init --preview keeps building (it scaffolds app.bicep and reuses ScaffoldBicepConfig). - init_test.go: drop the application prompt mock setup and the new 'create application - initial appname is invalid' test case; switch to common.ResultConfirmed and common.ProgressModel.
Mirror the rad init change for the --preview command: - Delete preview/application.go and preview/application_test.go. - Drop applicationOptions, the Application field on initOptions, and the enterApplicationOptions call in preview/options.go. - Replace the application scaffold step in preview/init.go with the same bicepconfig scaffold + warning flow used by rad init. The Application scaffold step is gone; a bicepconfig.json is always created and the user is warned if one already existed. - Update preview/display.go to populate common.BicepConfigDisplay so the shared summary/progress views render the bicepconfig step. - Strip setScaffoldApplicationPrompt* and setApplicationNamePrompt calls from preview/init_test.go, drop the 'create application - initial appname is invalid' test case and the helper functions, remove the Application field from the Test_Run options, and t.Chdir to a temp dir so bicepconfig scaffolding does not affect the source tree. - Remove pkg/cli/setup.ScaffoldApplication; nothing references it now.
Neither rad init nor rad init --preview scaffold an application any more, so the helpers and display fields that supported that flow are unused. - Delete pkg/cli/cmd/radinit/common/application.go and its test file (EnterApplicationOptions and the Confirm/Enter prompt constants). - Drop ApplicationDisplay, DisplayOptions.Application, and ProgressMsg.ApplicationComplete from common/display.go, along with the SummaryApplication* constants and the application branches in the summary/progress views and isComplete. - Update the rad init Run doc comment to say it scaffolds a bicepconfig.json (not an application).
Radius functional test overviewClick here to see the test run details
Test Status⌛ Building Radius and pushing container images for functional tests... |
Agent-Logs-Url: https://github.com/radius-project/radius/sessions/55a94f7d-e29d-4c3e-9965-e5fc1bcb3d8e Co-authored-by: zachcasper <30731731+zachcasper@users.noreply.github.com>
|
@brooke-hamilton PTAL |
|
Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Description
This PR fixes the failing Run Unit Tests GitHub Actions job by stabilizing reconciler test lifecycle behavior in
pkg/controller/reconciler.The failure was traced to test manager goroutines in reconciler tests using panic-based error handling and non-deterministic shutdown timing. I updated the test setup helpers to use deterministic manager startup/shutdown coordination with cleanup ordering that waits for
mgr.Start(...)to exit after cancellation, and only fails on unexpected non-cancellation errors.Type of change
Contributor checklist
Please verify that the PR meets the following requirements, where applicable:
eng/design-notes/in this repository, if new APIs are being introduced.