Repository navigation
[Research – do not merge] CI 10% probe: W1 base-layer change - #14633
Don Syme (dsyme) wants to merge 5 commits into
Conversation
Re-wires the BuildOptimization test selection (microsoft#7392) that was dropped when test projects moved to Invoke-PerProjectTestRun, and computes PR changes from the PR merge commit so base-branch changes missing from a stale PR branch are no longer treated as PR changes. Non-PR events still run every test app. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Same tree as microsoft#14631 head 478ea1c.
|
Could not find linked issues in the pull request description. Please make sure the pull request description contains a line that contains 'Fixes #' followed by the issue number being fixed. Use that pattern for every issue you want to link. |
|
|
||
| Context "Select-TestAppsToRun" { | ||
| BeforeAll { | ||
| $selectCache = Join-Path ([System.IO.Path]::GetTempPath()) "BuildOptimization_Select_$([System.Guid]::NewGuid()).json" |
| Describe "PullRequestBuildScope" { | ||
| BeforeAll { | ||
| Import-Module "$PSScriptRoot\..\PullRequestBuildScope.psm1" -Force | ||
| $countries = @('AT', 'AU', 'CA', 'CH', 'CZ', 'DE', 'FR', 'MX', 'NZ', 'US') |
|
|
||
| Context "Get-PullRequestTestBuildModes" { | ||
| BeforeAll { | ||
| $modes = @('IntegrationTests', 'UncategorizedTests', 'LegacyTestsBucket1', 'LegacyTestsBucket2') |
| '{ "LegacyTests-Bucket1": [ "Tests-ERM" ] }' | Set-Content (Join-Path $root 'build/scripts/TestConfiguration.json') | ||
|
|
||
| $eventFile = Join-Path $root 'event.json' | ||
| $saved = @($env:GITHUB_EVENT_NAME, $env:GITHUB_EVENT_PATH, $env:GITHUB_STEP_SUMMARY) |
| if: github.event_name == 'pull_request' | ||
| shell: pwsh | ||
| run: | | ||
| Import-Module ./build/scripts/PullRequestBuildScope.psm1 -Force |
There was a problem hiding this comment.
This pull_request workflow step imports and executes the module from the checked-out pull request before initialization, so a contributor can run arbitrary repository code in a job that declares id-token: write and other elevated GitHub permissions. Move this logic to a trusted, pinned action or isolate it in a least-privileged workflow that does not expose write-capable tokens.
👍 useful · ❤️ especially valuable · 👎 wrong - reply with why · AL review agent v10.0.7
|
Closing without merging: the W1 base-layer probe completed successfully (run 45877716069). It selected W1 only, but the layer change triggered the full-test fallback within that scope, including both legacy buckets. It used 152.9 GitHub-hosted job-min (1,154.3 across all runners). A cheaper W1 layer test profile is a separate follow-up, not a saving demonstrated here. See #14597. |
Research only. Do not merge. I'll close it once the run is measured.
Same stack as #14606 (#14630 + #14631, plus the research-only change-classification commit), with one probe commit: W1 base-layer change (
src/Layers/W1/BaseApp).Measures job-min per Pull Request Build run for this PR type, for the 10% ledger on #14597. Results go on #14606.
Related to #14597