diff --git a/.github/workflows/NativePipeline.yml b/.github/workflows/NativePipeline.yml index 690006c6f..e1205a5c4 100644 --- a/.github/workflows/NativePipeline.yml +++ b/.github/workflows/NativePipeline.yml @@ -23,11 +23,18 @@ jobs: - name: "Determine scope" id: scope run: | - if [ ${{ github.event_name }} == 'pull_request' ]; then + echo "Event name: '${{ github.event_name }}'" + if [ "${{ github.event_name }}" == "pull_request" ]; then echo "scope=--since --include '*-native'" >> $GITHUB_OUTPUT - elif [ {{ github.event_name }} != 'pull_request' ]; then + else echo "scope=--include '*-native'" >> $GITHUB_OUTPUT fi + - name: "Set Output" + id: set_output + run: echo "scope=${{ steps.scope.outputs.scope }}" >> $GITHUB_ENV + - name: "Debug Scope Output" + run: | + echo "Scope is: ${{ steps.set_output.outputs.scope }}" mendix-version: runs-on: ubuntu-22.04 steps: @@ -90,9 +97,9 @@ jobs: - name: "Install dependencies" run: yarn install --immutable - name: "Unit test" - run: yarn workspaces foreach --all run test + run: yarn workspaces foreach ${{ steps.set_output.outputs.scope }} run test - name: "Run build for development" - run: yarn workspaces foreach --all run build + run: yarn workspaces foreach ${{ steps.set_output.outputs.scope }} run build env: NODE_OPTIONS: --max_old_space_size=6144 - name: "Upload resources artifact" @@ -379,7 +386,7 @@ jobs: adb push "/Users/runner/work/native-widgets/native-widgets/detox/apps/app-appstore-debug-androidTest.apk" "/data/local/tmp/detox/Test.apk" adb shell pm install -r -g -t /data/local/tmp/detox/Application.apk 2>/dev/null adb shell pm install -r -g -t /data/local/tmp/detox/Test.apk 2>/dev/null - yarn workspaces foreach --all run test:e2e:android + yarn workspaces foreach ${{ steps.scope.outputs.scope }} run test:e2e:android - name: "Archive runtime logs" uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3 if: always() @@ -456,7 +463,7 @@ jobs: - name: List supported iOS devices run: applesimutils --list - name: "Run tests" - run: yarn workspaces foreach --all run test:e2e:ios + run: yarn workspaces foreach ${{ steps.scope.outputs.scope }} run test:e2e:ios - name: "Archive runtime logs" uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3 if: always()