diff --git a/.github/workflows/jan-electron-linter-and-test.yml b/.github/workflows/jan-electron-linter-and-test.yml index c369a7e4db..e39af30884 100644 --- a/.github/workflows/jan-electron-linter-and-test.yml +++ b/.github/workflows/jan-electron-linter-and-test.yml @@ -38,6 +38,7 @@ on: jobs: test-on-macos: + if : github.event_name != 'pull_request_target' runs-on: [self-hosted, macOS, macos-desktop] steps: - name: Getting the repo @@ -64,6 +65,31 @@ jobs: TURBO_TEAM: "macos" TURBO_TOKEN: "${{ secrets.TURBO_TOKEN }}" + test-on-macos-pr-target: + if : github.event_name == 'pull_request_target' + runs-on: [self-hosted, macOS, macos-desktop] + steps: + - name: Getting the repo + uses: actions/checkout@v3 + + - name: Installing node + uses: actions/setup-node@v3 + with: + node-version: 20 + + - name: "Cleanup cache" + continue-on-error: true + run: | + make clean + + - name: Linter and test + run: | + npm config set registry https://registry.npmjs.org --global + yarn config set registry https://registry.npmjs.org --global + make test + env: + CSC_IDENTITY_AUTO_DISCOVERY: "false" + test-on-windows: if: github.event_name == 'push' strategy: @@ -127,8 +153,36 @@ jobs: TURBO_TEAM: "windows" TURBO_TOKEN: "${{ secrets.TURBO_TOKEN }}" + test-on-windows-pr-target: + if: github.event_name == 'pull_request_target' + runs-on: windows-desktop-default-windows-security + steps: + - name: Getting the repo + uses: actions/checkout@v3 + + - name: Installing node + uses: actions/setup-node@v1 + with: + node-version: 20 + + # Clean cache, continue on error + - name: "Cleanup cache" + shell: powershell + continue-on-error: true + run: | + make clean + + - name: Linter and test + shell: powershell + run: | + npm config set registry https://registry.npmjs.org --global + yarn config set registry https://registry.npmjs.org --global + make test + + test-on-ubuntu: runs-on: [self-hosted, Linux, ubuntu-desktop] + if: github.event_name != 'pull_request_target' steps: - name: Getting the repo uses: actions/checkout@v3 @@ -154,3 +208,28 @@ jobs: TURBO_API: "${{ secrets.TURBO_API }}" TURBO_TEAM: "linux" TURBO_TOKEN: "${{ secrets.TURBO_TOKEN }}" + + test-on-ubuntu-pr-target: + runs-on: [self-hosted, Linux, ubuntu-desktop] + if: github.event_name == 'pull_request_target' + steps: + - name: Getting the repo + uses: actions/checkout@v3 + + - name: Installing node + uses: actions/setup-node@v3 + with: + node-version: 20 + + - name: "Cleanup cache" + continue-on-error: true + run: | + make clean + + - name: Linter and test + run: | + export DISPLAY=$(w -h | awk 'NR==1 {print $2}') + echo -e "Display ID: $DISPLAY" + npm config set registry https://registry.npmjs.org --global + yarn config set registry https://registry.npmjs.org --global + make test \ No newline at end of file