Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
freddydk committed Nov 13, 2024
2 parents 9f99c81 + 9c74777 commit 5127c3f
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .github/AL-Go-Settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"gitHubRunner": "ubuntu-latest",
"githubRunnerShell": "pwsh",
"generateDependencyArtifact": true,
"templateSha": "24dc50d1783486501102306b8e6d628882bbd79f",
"templateSha": "e6969a61fc2a49d277eab3cbcf24eeb4b819ed3c",
"RepoVersion": "1.0",
"artifact": "//24.0//first"
}
31 changes: 30 additions & 1 deletion .github/RELEASENOTES.copy.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,36 @@ Note that when using the preview version of AL-Go for GitHub, we recommend you U

### Issues

- Issue 1241 Increment Version Number might produce wrong app.json
- `deployTo<environment>` now has an additional property called DependencyInstallMode, which determines how dependencies are deployed if GenerateDependencyArtifact is true. Default value is `install` to install dependencies if not already installed. Other values are `ignore` for ignoring dependencies, `upgrade` for upgrading dependencies if possible and `forceUpgrade` for force upgrading dependencies.

### New Project Settings

- `pageScriptingTests` should be an array of page scripting test file specifications, relative to the AL-Go project. Examples of file specifications: `recordings/my*.yml` (for all yaml files in the recordings subfolder matching my\*.yml), `recordings` (for all \*.yml files in the recordings subfolder) or `recordings/test.yml` (for a single yml file)
- `doNotRunPageScriptingTests` can force the pipeline to NOT run the page scripting tests specified in pageScriptingTests. Note this setting can be set in a [workflow specific settings file](#where-are-the-settings-located) to only apply to that workflow
- `restoreDatabases` should be an array of events, indicating when you want to start with clean databases in the container. Possible events are: `BeforeBcpTests`, `BeforePageScriptingTests`, `BeforeEachTestApp`, `BeforeEachBcptTestApp`, `BeforeEachPageScriptingTest`

### New Repository Settings

- `trustedSigning` is a structure defining `Account`, `EndPoint` and `CertificateProfile` if you want to use trusted signing. Note that your Azure_Credentials secret (Microsoft Entra ID App or Managed identity) still needs to provide access to your azure subscription and be assigned the `Trusted Signing Certificate Profile Signer` role in the Trusted Signing Account.

### Support for Azure Trusted Signing

Read https://learn.microsoft.com/en-us/azure/trusted-signing/ for more information about Trusted Signing and how to set it up. After setting up your trusted signing account and certificate profile, you need to create a setting called [trustedSigning](https://aka.ms/algosettings#trustedSigning) for AL-Go to sign your apps using Azure Trusted Signing.

### Support for Page Scripting Tests

Page Scripting tests are now supported as part of CI/CD. By specifying pageScriptingTests in your project settings file, AL-Go for GitHub will automatically run these page scripting tests as part of your CI/CD workflow, generating the following build artifacts:

- `PageScriptingTestResults` is a JUnit test results file with all results combined.
- `PageScriptingTestResultDetails` are the detailed test results (including videos) when any of the page scripting tests have failures. If the page scripting tests succeed - the details are not published.

## v6.0

### Issues

- Issue 1184 Publish to Environment fails on 'Permission Denied'
- AL Language extension in 25.0 doesn't contain the linux executable, use dotnet to invoke the dll instead.

### New Settings

Expand Down Expand Up @@ -649,7 +678,7 @@ Setting the repo setting "runs-on" to "Ubuntu-Latest", followed by running Updat
### CI/CD and Publish To New Environment

- Base functionality for selecting a specific GitHub runner for an environment
- Include dependencies artifacts when deploying (if generateDependencyArtifacts is true)
- Include dependencies artifacts when deploying (if generateDependencyArtifact is true)

### localDevEnv.ps1 and cloudDevEnv.ps1

Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/CICD.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ on:
- '!.github/workflows/CICD.yaml'
branches: [ 'main', 'release/*', 'feature/*', 'development' ]

concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true

defaults:
run:
shell: pwsh
Expand Down
17 changes: 9 additions & 8 deletions .github/workflows/_BuildALGoProject.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ jobs:
buildMode: ${{ inputs.buildMode }}
installAppsJson: ${{ steps.DownloadProjectDependencies.outputs.DownloadedApps }}
installTestAppsJson: ${{ steps.DownloadProjectDependencies.outputs.DownloadedTestApps }}
baselineWorkflowRunId: ${{ inputs.baselineWorkflowRunId }}
baselineWorkflowSHA: ${{ inputs.baselineWorkflowSHA }}

- name: Sign
Expand All @@ -191,7 +192,7 @@ jobs:
suffix: ${{ inputs.artifactsNameSuffix }}

- name: Upload thisbuild artifacts - apps
if: inputs.publishThisBuildArtifacts
if: inputs.publishThisBuildArtifacts && (hashFiles(format('{0}/.buildartifacts/Apps/*',inputs.project)) != '')
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: ${{ steps.calculateArtifactsNames.outputs.ThisBuildAppsArtifactsName }}
Expand All @@ -200,7 +201,7 @@ jobs:
retention-days: 1

- name: Upload thisbuild artifacts - dependencies
if: inputs.publishThisBuildArtifacts
if: inputs.publishThisBuildArtifacts && (hashFiles(format('{0}/.buildartifacts/Dependencies/*',inputs.project)) != '')
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: ${{ steps.calculateArtifactsNames.outputs.ThisBuildDependenciesArtifactsName }}
Expand All @@ -209,7 +210,7 @@ jobs:
retention-days: 1

- name: Upload thisbuild artifacts - test apps
if: inputs.publishThisBuildArtifacts
if: inputs.publishThisBuildArtifacts && (hashFiles(format('{0}/.buildartifacts/TestApps/*',inputs.project)) != '')
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: ${{ steps.calculateArtifactsNames.outputs.ThisBuildTestAppsArtifactsName }}
Expand All @@ -219,23 +220,23 @@ jobs:

- name: Publish artifacts - apps
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
if: inputs.publishArtifacts
if: inputs.publishArtifacts && (hashFiles(format('{0}/.buildartifacts/Apps/*',inputs.project)) != '')
with:
name: ${{ steps.calculateArtifactsNames.outputs.AppsArtifactsName }}
path: '${{ inputs.project }}/.buildartifacts/Apps/'
if-no-files-found: ignore

- name: Publish artifacts - dependencies
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
if: inputs.publishArtifacts && env.generateDependencyArtifact == 'True'
if: inputs.publishArtifacts && env.generateDependencyArtifact == 'True' && (hashFiles(format('{0}/.buildartifacts/Dependencies/*',inputs.project)) != '')
with:
name: ${{ steps.calculateArtifactsNames.outputs.DependenciesArtifactsName }}
path: '${{ inputs.project }}/.buildartifacts/Dependencies/'
if-no-files-found: ignore

- name: Publish artifacts - test apps
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
if: inputs.publishArtifacts && exists('${{ inputs.project }}/.buildartifacts/TestApps/')
if: inputs.publishArtifacts && (hashFiles(format('{0}/.buildartifacts/TestApps/*',inputs.project)) != '')
with:
name: ${{ steps.calculateArtifactsNames.outputs.TestAppsArtifactsName }}
path: '${{ inputs.project }}/.buildartifacts/TestApps/'
Expand Down Expand Up @@ -283,15 +284,15 @@ jobs:

- name: Publish artifacts - page scripting test result details
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
if: (success() || failure())
if: (success() || failure()) && (hashFiles(format('{0}/.buildartifacts/PageScriptingTestResultDetails/*',inputs.project)) != '')
with:
name: ${{ steps.calculateArtifactsNames.outputs.PageScriptingTestResultDetailsArtifactsName }}
path: '${{ inputs.project }}/.buildartifacts/PageScriptingTestResultDetails/'
if-no-files-found: ignore

- name: Analyze Test Results
id: analyzeTestResults
if: (success() || failure()) && env.doNotRunTests == 'False'
if: (success() || failure()) && env.doNotRunTests == 'False' && ((hashFiles(format('{0}/.buildartifacts/TestResults.xml',inputs.project)) != '') || (hashFiles(format('{0}/.buildartifacts/bcptTestResults.json',inputs.project)) != ''))
uses: freddydk/AL-Go/Actions/AnalyzeTests@partial
with:
shell: ${{ inputs.shell }}
Expand Down
2 changes: 1 addition & 1 deletion BO-DK/DK/HelloWorld.al
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ pageextension 61000 CustomerListExtDK extends "Customer List"
{
trigger OnOpenPage();
begin
// Message('App published: Hello world!!!!!');
// Message('App published: Hello world!');
end;
}

0 comments on commit 5127c3f

Please sign in to comment.