@@ -44,16 +44,17 @@ jobs:
4444 - uses : actions/checkout@v3
4545 with :
4646 ref : ${{ github.base_ref }}
47- - name : Use Node.js v20.9.0
47+ - name : Use Node.js 20.x
4848 uses : actions/setup-node@v3
4949 with :
50- node-version : v20.9.0
50+ node-version : 20
5151
5252 - name : Install dependencies
5353 run : |
54+ make config-yarn
5455 yarn
55- yarn build:core
5656 yarn build:joi
57+ yarn build:core
5758
5859 - name : Run test coverage
5960 run : yarn test:coverage
6667
6768 test-on-macos :
6869 if : (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
69- runs-on : [self-hosted, macOS, macos-desktop]
70+ runs-on : macos-latest
7071 steps :
7172 - name : Getting the repo
7273 uses : actions/checkout@v3
7879 with :
7980 node-version : 20
8081
82+ - name : Set IS_TEST environment variable
83+ run : |
84+ echo "IS_TEST=true" >> $GITHUB_ENV
85+
8186 - name : ' Cleanup cache'
8287 continue-on-error : true
8388 run : |
@@ -94,24 +99,19 @@ jobs:
9499 run : |
95100 echo "REPORT_PORTAL_DESCRIPTION=${{github.sha}})" >> $GITHUB_ENV
96101
97- - name : ' Config report portal'
98- run : |
99- make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App macos" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
102+ # - name: 'Config report portal'
103+ # run: |
104+ # make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App macos" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
100105
101106 - name : Linter and test
102107 run : |
103- npm config set registry ${{ secrets.NPM_PROXY }} --global
104- yarn config set registry ${{ secrets.NPM_PROXY }} --global
105108 make test
106109 env :
107110 CSC_IDENTITY_AUTO_DISCOVERY : ' false'
108- # TURBO_API: '${{ secrets.TURBO_API }}'
109- # TURBO_TEAM: 'macos'
110- # TURBO_TOKEN: '${{ secrets.TURBO_TOKEN }}'
111111
112112 test-on-macos-pr-target :
113113 if : github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository
114- runs-on : [self-hosted, macOS, macos-desktop]
114+ runs-on : macos-latest
115115 steps :
116116 - name : Getting the repo
117117 uses : actions/checkout@v3
@@ -131,8 +131,6 @@ jobs:
131131
132132 - name : Linter and test
133133 run : |
134- npm config set registry https://registry.npmjs.org --global
135- yarn config set registry https://registry.npmjs.org --global
136134 make test
137135 env :
138136 CSC_IDENTITY_AUTO_DISCOVERY : ' false'
@@ -174,32 +172,27 @@ jobs:
174172 run : |
175173 echo "REPORT_PORTAL_DESCRIPTION=${{github.sha}}" >> $GITHUB_ENV
176174
177- - name : ' Config report portal'
178- shell : bash
179- run : |
180- make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Windows ${{ matrix.antivirus-tools }}" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
175+ # - name: 'Config report portal'
176+ # shell: bash
177+ # run: |
178+ # make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Windows ${{ matrix.antivirus-tools }}" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
181179
182180 - name : Linter and test
183181 shell : powershell
184182 run : |
185- npm config set registry ${{ secrets.NPM_PROXY }} --global
186- yarn config set registry ${{ secrets.NPM_PROXY }} --global
187183 make test
188- # env:
189- # TURBO_API: '${{ secrets.TURBO_API }}'
190- # TURBO_TEAM: 'windows'
191- # TURBO_TOKEN: '${{ secrets.TURBO_TOKEN }}'
184+
192185 test-on-windows-pr :
193- if : (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository)
194- runs-on : windows-desktop-default-windows-security
186+ if : (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'workflow_dispatch'
187+ runs-on : windows-latest
195188 steps :
196189 - name : Getting the repo
197190 uses : actions/checkout@v3
198191 with :
199192 fetch-depth : 0
200193
201194 - name : Installing node
202- uses : actions/setup-node@v1
195+ uses : actions/setup-node@v3
203196 with :
204197 node-version : 20
205198
@@ -222,25 +215,19 @@ jobs:
222215 run : |
223216 echo "REPORT_PORTAL_DESCRIPTION=${{github.event.after}}" >> $GITHUB_ENV
224217
225- - name : ' Config report portal'
226- shell : bash
227- run : |
228- make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Windows" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
218+ # - name: 'Config report portal'
219+ # shell: bash
220+ # run: |
221+ # make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Windows" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
229222
230223 - name : Linter and test
231224 shell : powershell
232225 run : |
233- npm config set registry ${{ secrets.NPM_PROXY }} --global
234- yarn config set registry ${{ secrets.NPM_PROXY }} --global
235226 make test
236- # env:
237- # TURBO_API: '${{ secrets.TURBO_API }}'
238- # TURBO_TEAM: 'windows'
239- # TURBO_TOKEN: '${{ secrets.TURBO_TOKEN }}'
240227
241228 test-on-windows-pr-target :
242229 if : github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository
243- runs-on : windows-desktop-default-windows-security
230+ runs-on : windows-latest
244231 steps :
245232 - name : Getting the repo
246233 uses : actions/checkout@v3
@@ -268,12 +255,10 @@ jobs:
268255 - name : Linter and test
269256 shell : powershell
270257 run : |
271- npm config set registry https://registry.npmjs.org --global
272- yarn config set registry https://registry.npmjs.org --global
273258 make test
274259
275260 test-on-ubuntu :
276- runs-on : [self-hosted, Linux, ubuntu-desktop]
261+ runs-on : ubuntu-latest
277262 if : (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
278263 steps :
279264 - name : Getting the repo
@@ -302,22 +287,16 @@ jobs:
302287 run : |
303288 echo "REPORT_PORTAL_DESCRIPTION=${{github.sha}}" >> $GITHUB_ENV
304289
305- - name : ' Config report portal'
306- shell : bash
307- run : |
308- make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Linux" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
290+ # - name: 'Config report portal'
291+ # shell: bash
292+ # run: |
293+ # make update-playwright-config REPORT_PORTAL_URL=${{ secrets.REPORT_PORTAL_URL }} REPORT_PORTAL_API_KEY=${{ secrets.REPORT_PORTAL_API_KEY }} REPORT_PORTAL_PROJECT_NAME=${{ secrets.REPORT_PORTAL_PROJECT_NAME }} REPORT_PORTAL_LAUNCH_NAME="Jan App Linux" REPORT_PORTAL_DESCRIPTION="${{env.REPORT_PORTAL_DESCRIPTION}}"
309294
310295 - name : Linter and test
311296 run : |
312297 export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
313298 echo -e "Display ID: $DISPLAY"
314- npm config set registry ${{ secrets.NPM_PROXY }} --global
315- yarn config set registry ${{ secrets.NPM_PROXY }} --global
316299 make test
317- # env:
318- # TURBO_API: '${{ secrets.TURBO_API }}'
319- # TURBO_TEAM: 'linux'
320- # TURBO_TOKEN: '${{ secrets.TURBO_TOKEN }}'
321300
322301 - uses : actions/upload-artifact@v4
323302 if : always()
@@ -327,7 +306,7 @@ jobs:
327306 retention-days : 2
328307
329308 coverage-check :
330- runs-on : [self-hosted, Linux, ubuntu-desktop]
309+ runs-on : ubuntu-latest
331310 needs : base_branch_cov
332311 if : (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository) || github.event_name == 'push' || github.event_name == 'workflow_dispatch'
333312 steps :
@@ -341,6 +320,9 @@ jobs:
341320 with :
342321 node-version : 20
343322
323+ - name : Install yarn
324+ run : npm install -g yarn
325+
344326 - name : ' Cleanup cache'
345327 continue-on-error : true
346328 run : |
@@ -356,15 +338,9 @@ jobs:
356338 run : |
357339 export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
358340 echo -e "Display ID: $DISPLAY"
359- npm config set registry ${{ secrets.NPM_PROXY }} --global
360- yarn config set registry ${{ secrets.NPM_PROXY }} --global
361341 make lint
362342 yarn build:test
363343 yarn test:coverage
364- # env:
365- # TURBO_API: '${{ secrets.TURBO_API }}'
366- # TURBO_TEAM: 'linux'
367- # TURBO_TOKEN: '${{ secrets.TURBO_TOKEN }}'
368344
369345 - name : Generate Code Coverage report
370346 id : code-coverage
@@ -377,7 +353,7 @@ jobs:
377353 show-annotations : ' warning'
378354
379355 test-on-ubuntu-pr-target :
380- runs-on : [self-hosted, Linux, ubuntu-desktop]
356+ runs-on : ubuntu-latest
381357 if : github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository
382358 steps :
383359 - name : Getting the repo
@@ -400,6 +376,4 @@ jobs:
400376 run : |
401377 export DISPLAY=$(w -h | awk 'NR==1 {print $2}')
402378 echo -e "Display ID: $DISPLAY"
403- npm config set registry https://registry.npmjs.org --global
404- yarn config set registry https://registry.npmjs.org --global
405379 make test
0 commit comments