Skip to content

Build, test and release the framework from GitHub Actions - #53

Merged
RoelantVos merged 4 commits into
mainfrom
feature/release-pipeline
Oct 26, 2026
Merged

RoelantVos merged 4 commits into
mainfrom
feature/release-pipeline

Conversation

@RoelantVos

@RoelantVos RoelantVos commented Oct 26, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Adds the Build and release workflow (.github/workflows/release.yml), the release pipeline of the framework.

  • Build (Windows): checks that .direct-version, Directory.Build.props, Releases.Direct_Framework/next/version.json, the DIRECT_VERSION seed and Documentation/ReleaseNotes.md agree on the version, builds Direct_Framework.sqlproj in Release, copies the output to Releases.Direct_Framework/next/db (the project's post-build script does not see the configuration of a dotnet build and leaves the tracked dacpac in place), checks that the dacpac carries the version under test, and uploads it.
  • Integration tests (Linux): installs go-sqlcmd, replaces the next release folder with that build output and runs the Testcontainers based test project in Debug (as RunTestsSimple.ps1 does; in Release the NuGet audit of transitive packages fails the restore), so the tests cover the build under test and not the dacpac checked into the repository.
  • Release (push to main only, or a manual run with publish ticked): when the release v<version> does not exist yet, publishes it with the notes from the ## Release <version> section of ReleaseNotes.md, a compare link to the previous tag, and the assets Direct_Framework.dacpac, master.dacpac (as in v2.1.2), Direct_Fabric.zip (the fabric folder) and Direct_Snowflake.sql. When the release exists the job ends with a notice, so ordinary merges do not fail.

Pull requests run build and tests only. A release is therefore cut by merging the version bump; merging this PR publishes v2.2.0, since .direct-version is already 2.2.0 and no such release exists.

Also:

Testing

  • Run 4 on this PR is green: the Windows build produces the 2.2.0.0 dacpac, and all 23 integration tests pass on the Linux runner against it (about 4 minutes, Testcontainers with the SQL Server 2022 image). The release job is skipped on pull requests as intended.
  • Earlier runs found and fixed: the NuGet audit failing the Release restore of the test project (SSH.NET and System.Security.Cryptography.Pkcs through Testcontainers and DacFx), the post-build script leaving the old dacpac in place, and the missing sqlcmd on the runner.

🤖 Generated with Claude Code

https://claude.ai/code/session_01P8xKsmMZRuuoGUZqqpAmVK

Add the Build and release workflow: every pull request and push to main builds the dacpac on Windows and runs the integration tests on Linux against that build; a push to main publishes the GitHub release v<version> when the version in .direct-version has none yet, with the notes from the matching section of ReleaseNotes.md and the dacpacs, the fabric folder and the Snowflake script as assets. The version files are checked for agreement before the build.

Also lowercase the current and next folder names in the migration tests so they run on Linux, add the Snowflake edition to the 2.2.0 release notes, and describe the release flow in the README.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01P8xKsmMZRuuoGUZqqpAmVK
The Release configuration treats warnings as errors, and the NuGet audit of the test project's transitive packages (SSH.NET via Testcontainers, System.Security.Cryptography.Pkcs via DacFx) reports vulnerabilities, so the restore failed on the Linux runner. The repository's own test runner uses Debug.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01P8xKsmMZRuuoGUZqqpAmVK
The project's post-build script did not see the Release configuration on the runner and left the tracked, older dacpac in the next release folder, so the tests ran against DIRECT 2.1.0 and 15 of them failed on the missing procedures. The workflow now copies bin/Release to the next release folder itself and fails when the dacpac's DacMetadata version is not the version under test. The test results folder is addressed from the workspace root so the trx is uploaded.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01P8xKsmMZRuuoGUZqqpAmVK
The migration test runs the pre-dacpac deployment script through sqlcmd, which the Linux runner does not have; 22 of 23 tests passed without it. Install go-sqlcmd 1.10.0 before the tests.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01P8xKsmMZRuuoGUZqqpAmVK
@RoelantVos
RoelantVos merged commit 7945792 into main Oct 26, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants