microsoft/TypeAgent

Public

mirrored from https://github.com/microsoft/TypeAgentAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
9ee1ac3453bf4e9db2ce2193962af8e460edaa40

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

.github/workflows/shell-tests.yml

133lines · modecode

1# Copyright (c) Microsoft Corporation.
2# Licensed under the MIT License.
3
4name: Shell Tests - Full Suite
5on:
6 #push:
7 # branches: ["main"]
8 schedule:
9 - cron: "0 0 * * *" #start of every day
10
11permissions:
12 id-token: write
13 contents: read
14
15env:
16 NODE_OPTIONS: --max_old_space_size=8192
17# DEBUG: pw:browser* # PlayWright debug messages
18# ELECTRON_ENABLE_LOGGING: true # Electron debug messages
19# DEBUG: typeagent:* # TypeAgent debug messages
20
21# run only one of these at a time
22concurrency:
23 group: ${{ github.workflow }}
24 cancel-in-progress: true
25
26jobs:
27 build_ts:
28 strategy:
29 fail-fast: false
30 matrix:
31 os: ["windows-latest", "ubuntu-latest"]
32 version: [20]
33
34 runs-on: ${{ matrix.os }}
35 steps:
36 - if: runner.os == 'Linux'
37 run: |
38 sudo apt install libsecret-1-0
39
40 - name: Setup Git LF
41 run: |
42 git config --global core.autocrlf false
43
44 - uses: actions/checkout@v4
45
46 - uses: dorny/paths-filter@v3
47 id: filter
48 with:
49 filters: |
50 ts:
51 - "ts/**"
52 - ".github/workflows/build-ts.yml"
53
54 - uses: pnpm/action-setup@v4
55 name: Install pnpm
56 with:
57 package_json_file: ts/package.json
58
59 - uses: actions/setup-node@v4
60 with:
61 node-version: ${{ matrix.version }}
62 cache: "pnpm"
63 cache-dependency-path: ts/pnpm-lock.yaml
64
65 - name: Install dependencies (pnpm)
66 working-directory: ts
67 run: |
68 pnpm install --frozen-lockfile --strict-peer-dependencies
69
70 - name: Install Playwright Browsers
71 run: pnpm exec playwright install --with-deps
72 working-directory: ts/packages/shell
73
74 - name: Build repo
75 working-directory: ts
76 run: |
77 npm run build
78
79 - name: Login to Azure
80 uses: azure/login@v2.2.0
81 with:
82 client-id: ${{ secrets.AZUREAPPSERVICE_CLIENTID_5B0D2D6BA40F4710B45721D2112356DD }}
83 tenant-id: ${{ secrets.AZUREAPPSERVICE_TENANTID_39BB903136F14B6EAD8F53A8AB78E3AA }}
84 subscription-id: ${{ secrets.AZUREAPPSERVICE_SUBSCRIPTIONID_F36C1F2C4B2C49CA8DD5C52FAB98FA30 }}
85
86 - name: Get Keys
87 run: |
88 node tools/scripts/getKeys.mjs --vault build-pipeline-kv
89 working-directory: ts
90
91 - name: Test CLI - verify .env & endpoint connectivity
92 run: |
93 npm run start:dev 'prompt' 'why is the sky blue'
94 working-directory: ts/packages/cli
95
96 - name: Shell Tests (windows)
97 if: ${{ runner.os == 'windows' }}
98 timeout-minutes: 60
99 run: |
100 npm run shell:test
101 working-directory: ts/packages/shell
102 continue-on-error: true
103
104 - name: Shell Tests (linux)
105 if: ${{ runner.os == 'Linux' }}
106 timeout-minutes: 60
107 run: |
108 Xvfb :99 -screen 0 1600x1200x24 & export DISPLAY=:99
109 npm run shell:test
110 working-directory: ts/packages/shell
111 continue-on-error: true
112
113 - uses: actions/upload-artifact@v4
114 if: ${{ !cancelled() }}
115 with:
116 name: test-results
117 path: ts/packages/shell/test-results/
118 overwrite: true
119 retention-days: 30
120
121 - uses: actions/upload-artifact@v4
122 if: ${{ !cancelled() }}
123 with:
124 name: playwright-report
125 path: ts/packages/shell/playwright-report/
126 overwrite: true
127 retention-days: 30
128
129 - name: Clean up Keys
130 run: |
131 rm ./.env
132 working-directory: ts
133 if: always()
134