Repository navigation
Migrate build to go-task and CI to GitHub Actions - #24
Merged
Merged
Conversation
Replace the Nuke build (build/, build.cmd|ps1|sh, .nuke) with a Taskfile and switch versioning from GitVersion to Nerdbank.GitVersioning (version.json, src/Directory.Build.props). Point the Azure pipeline at the task targets and check in the VSTO signing key so CI can import it. Also fix interop OnNew ordering (existing worksheets are notified before the workbook; worksheets added during OnNew(workbook) are notified by Workbook itself), drop the empty-file PDF/XPS save guard in Headless, and update tests with blank.xlsx fixtures.
Add ci.yml (Excel32/Excel64 matrix on windows-latest: installs Office via choco, imports the VSTO signing cert, runs task ci, publishes test results and nupkg artifacts) and release.yml (v* tag triggered: packs and pushes to NuGet.org via OIDC trusted publishing, then creates a GitHub release). Allow public release versions on v* tags in version.json, swap the README badge, and drop azure-pipelines.yml.
Test Results (Excel64) 5 files 8 suites 7m 42s ⏱️ Results for commit bf73f9e. ♻️ This comment has been updated with latest results. |
Test Results (Excel32) 5 files 8 suites 6m 12s ⏱️ Results for commit bf73f9e. ♻️ This comment has been updated with latest results. |
A failing pass (e.g. one flaky VSTO test) aborted task test at that command, so later passes never ran and produced no result files. Run all five passes in one script, collect the failing pass names, and fail at the end when any pass failed.
The 1G-char case (a 2 GB BSTR) cannot be marshaled into 32-bit Excel over COM and fails with E_OUTOFMEMORY on every Excel32 run. SetString is a passthrough to a single DocumentProperties value, so the 1G case stressed Excel rather than this library; 1M chars already proves arbitrary-length support well past the native property limit.
On CI, Excel intermittently dies mid-Workbook.Close (RPC failure 0x800706BE, observed after ShowInputMessage leaves an input-message validation on the workbook), failing tests whose assertions had already passed. Harden the four interop test fixtures: snapshot the Workbooks collection before closing (closing while enumerating the live COM collection is undefined), catch COMException around Close/Quit, and kill the Excel process by pid - captured at construction, while the Hwnd is still resolvable - so a hung instance cannot leak into later tests.
actions/checkout@v6, setup-dotnet@v5 and upload-artifact@v7 replace the v4 versions, which run on Node 20 and get force-switched to Node 24 on June 16, 2026.
The Dna and Vsto test projects carried four verbatim copies of the Excel fixture (application setup, pid capture, AddWorkbook, the crash-tolerant teardown). Single inheritance forbids one common base for all four - they derive from two different fact bases - so the logic moves to a fixture object fronted by one thin abstract base per test kind. New Allors.Excel.Interop.Tests.Shared project (net462, not packable): InteropExcelFixture owns all the logic; InteropWorksheetTests and InteropWorkbookTests delegate to it. The per-project classes are now empty shells whose namespaces keep the per-suite test names in CI reporting.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the Nuke build with a go-task Taskfile and moves CI from Azure Pipelines to GitHub Actions.
Build (commit 1)
Taskfile.ymlreplacesbuild/+build.cmd|ps1|sh+.nuke(targets:restore,compile,test,pack,ci)version.json, auto-referenced viasrc/Directory.Build.props)OnNewevent-ordering fixes, headless PDF/XPS save fix, test fixtures (blank.xlsx), VSTO signing key checked in for CI importCI (commit 2)
ci.yml- push/PR to main + manual dispatch. Excel32/Excel64 matrix onwindows-latest: installs Office via choco (--forcex86for the 32-bit lane), imports the VSTO cert, runstask ci CONFIGURATION=Release. Test results published as check runs (xunit XML + TRX) and uploaded as artifacts; nupkgs packed and uploaded on the Excel64 lane.release.yml-v*.*.*tags + manual dispatch. Packs and pushes to NuGet.org via OIDC trusted publishing (nuget/login@v1, userallors-nuget, environmentnuget-release,--skip-duplicate), then creates a GitHub release. No long-lived API key.version.json:v*tags added topublicReleaseRefSpecso tag builds get public versionsazure-pipelines.ymlremovedConventions mirror allors/tram-dotnet (v4 actions, concurrency group, ci/release split). Divergence: the release workflow packs but does not re-run tests (they need a ~20 min Office install; the tagged commit is already green on main).
Before the first release
allors-nuget): add a Trusted Publishing policy - ownerallors, repoexcel, workflowrelease.yml, environmentnuget-releasenuget-releaseenvironment (optionally with required reviewers)nbgv tagso the tag matches the computed versionExcel/ExcelfeedThe CI run on this PR is the end-to-end verification (both Excel lanes).