Skip to content

Commit 1b2f74a

Browse files
authored
fix: issue with power apps and test in ci (#440)
* fix: issue with power apps and test in ci * chore: rename ci job
1 parent a791fe6 commit 1b2f74a

File tree

6 files changed

+438
-25
lines changed

6 files changed

+438
-25
lines changed

.github/workflows/01-build-power-apps.yml

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
name: Deploy Power Apps
2+
name: Build Power Apps
33

44
on:
55
workflow_call:
@@ -9,8 +9,8 @@ on:
99
type: string
1010

1111
jobs:
12-
build-showcases:
13-
name: Deploy Power Apps
12+
build-power-apps:
13+
name: Build Power Apps
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: ⬇ Checkout repo
@@ -51,18 +51,6 @@ jobs:
5151
name: db-ui-powerapps
5252
path: build-power-apps/DBUI
5353

54-
- name: ⬆ Upload Release Asset
55-
id: upload-release-asset
56-
uses: actions/github-script@v6
57-
with:
58-
result-encoding: json
59-
script: |
60-
const { default: uploadAsset } = await import('${{ github.workspace }}/.github/scripts/upload-asset.js');
61-
const release_id = context.payload.release.id;
62-
const assetName = 'DBUI.zip';
63-
const assetPath = '${{ github.workspace }}/build-power-apps/DBUI/bin/Release/DBUI.zip';
64-
return await uploadAsset({github, context, release_id, assetName, assetPath});
65-
6654
- name: 💀 Killing me softly
6755
uses: ./.github/actions/cancel-workflow
6856
if: failure()

.github/workflows/03-publish-packages.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ jobs:
3333
name: db-ui-outputs
3434
path: build-outputs
3535

36+
- name: ⬇ Download Power Apps zip
37+
uses: ./.github/actions/download-tar-artifact
38+
with:
39+
name: db-ui-powerapps
40+
path: build-power-apps/DBUI
41+
3642
- name: 📰 Publish to NPM Registries
3743
run: |
3844
chmod +rx ./.github/scripts/publish-npm.sh
@@ -44,6 +50,18 @@ jobs:
4450
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
4551
GPR_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4652

53+
- name: ⬆ Upload Power Apps Release Asset
54+
id: upload-release-asset
55+
uses: actions/github-script@v6
56+
with:
57+
result-encoding: json
58+
script: |
59+
const { default: uploadAsset } = await import('${{ github.workspace }}/.github/scripts/upload-asset.js');
60+
const release_id = context.payload.release.id;
61+
const assetName = 'DBUI.zip';
62+
const assetPath = '${{ github.workspace }}/build-power-apps/DBUI/bin/Release/DBUI.zip';
63+
return await uploadAsset({github, context, release_id, assetName, assetPath});
64+
4765
- name: 💀 Killing me softly
4866
uses: ./.github/actions/cancel-workflow
4967
if: failure()

.github/workflows/default.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,19 @@ jobs:
3535
uses: ./.github/workflows/01-build-showcases.yml
3636
needs: [build-packages]
3737

38+
build-power-apps:
39+
uses: ./.github/workflows/01-build-power-apps.yml
40+
needs: [build-packages]
41+
secrets: inherit
42+
with:
43+
version: 0.0.0-test
44+
3845
checks-done:
3946
runs-on: ubuntu-latest
4047
steps:
4148
- name: 🎉 Checks done
4249
run: echo "🎉 All tests were successful."
43-
needs: [build-showcases, build-outputs, test-packages]
50+
needs: [build-showcases, build-outputs, test-packages, build-power-apps]
4451

4552
deploy:
4653
uses: ./.github/workflows/03-deploy-gh-pages.yml

.github/workflows/release.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,19 @@ jobs:
3636
uses: ./.github/workflows/02-e2e.yml
3737
needs: [build-packages]
3838

39+
build-power-apps:
40+
uses: ./.github/workflows/01-build-power-apps.yml
41+
needs: [get-publish-version, build-packages]
42+
secrets: inherit
43+
with:
44+
version: ${{ needs.get-publish-version.outputs.version }}
45+
3946
checks-done:
4047
runs-on: ubuntu-latest
4148
steps:
4249
- name: 🎉 Checks done
4350
run: echo "🎉 All builds were successful."
44-
needs: [test-packages, build-outputs, build-showcases]
51+
needs: [test-packages, build-outputs, build-showcases, build-power-apps]
4552

4653
deploy:
4754
uses: ./.github/workflows/03-deploy-gh-pages.yml
@@ -50,13 +57,6 @@ jobs:
5057
release: ${{ needs.get-publish-version.outputs.release }}
5158
preRelease: ${{ needs.get-publish-version.outputs.preRelease }}
5259

53-
build-power-apps:
54-
uses: ./.github/workflows/01-build-power-apps.yml
55-
needs: [get-publish-version, checks-done, build-packages]
56-
secrets: inherit
57-
with:
58-
version: ${{ needs.get-publish-version.outputs.version }}
59-
6060
publishpackages:
6161
uses: ./.github/workflows/03-publish-packages.yml
6262
needs: [get-publish-version, checks-done, build-outputs]

0 commit comments

Comments
 (0)