Conversation
There was a problem hiding this comment.
Pull request overview
This PR introduces the concept of test projects to AL-Go for GitHub — a new project type that separates test execution from compilation. A test project does not build any apps; instead, it depends on one or more regular projects, installs the apps they produce (including test apps), and runs tests against them. This enables re-running tests without a full rebuild.
Changes:
- New
testProjectsetting for project-level.AL-Go/settings.json, with schema validation, default value, and documentation - Dependency resolution and build order logic to treat test projects as dependents of their upstream projects
- Pipeline changes to correctly handle running a test project with no local app/test folders
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
Actions/AL-Go-Helper.ps1 |
Adds testProject handling in AnalyzeRepo (validates no buildable code, sets test runner flags) and AnalyzeProjectDependencies (injects build-order dependencies via synthetic markers) |
Actions/RunPipeline/RunPipeline.ps1 |
Skips the "repository is empty" early exit for test projects |
Actions/.Modules/ReadSettings.psm1 |
Adds testProject with an empty-array default to the settings defaults |
Actions/.Modules/settings.schema.json |
Adds testProject as an array-of-strings property to the JSON schema |
Scenarios/settings.md |
Documents the new testProject setting |
RELEASENOTES.md |
Describes the test projects feature and its usage |
Tests/DetermineProjectsToBuild.Test.ps1 |
Adds six new test scenarios covering dependency resolution, validation errors, transitive deps, and multi-upstream cases |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Actions/AL-Go-Helper.ps1
Outdated
| OutputError "Test project '$project' references '$resolvedTarget' which is also a test project. A test project cannot depend on another test project." | ||
| throw | ||
| } | ||
| # Insert 'fake' app to force dependency from test project to target project |
There was a problem hiding this comment.
Not a great fan of such shenanigans, but ok 😄
There was a problem hiding this comment.
Yeah maybe not the best approach. I did a small update that injects test dependencies into $foundDependencies.
❔What, Why & How
This new feature brings the concept of test projects to AL-Go for GitHub. The purpose of this is to allow the user to split building and testing into separate projects. This can be especially useful if some tests are unstable and might require a re-run to succeed. In such scenarios, it's nice not to have to wait for compilation again.
A test project is a special type of project that depends on one or more regular projects. It will download and install artifacts from those dependent projects and run all test apps it finds. It allows any customization or settings used in regular projects, such as build modes or conditional settings. The only limitation is test projects are not allowed to build apps.
Related to issue: #
✅ Checklist