Skip to content

Commit

Permalink
test: update vsc tester version
Browse files Browse the repository at this point in the history
  • Loading branch information
ayachensiyuan committed Apr 19, 2024
1 parent c792581 commit b37d9b9
Showing 1 changed file with 7 additions and 31 deletions.
38 changes: 7 additions & 31 deletions .github/workflows/ui-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,8 @@ permissions:
jobs:
setup:
runs-on: ubuntu-latest
environment: engineering
permissions:
id-token: write
contents: read
env:
ADO_TOKEN: ${{ secrets.ADO_PAT }}
AUTO_TEST_PLAN_ID: ${{ github.event.inputs.source-testplan-id }}
TARGET_TEST_PLAN_NAME: ${{ github.event.inputs.target-testplan-name }}
DEVTUNNEL_CLIENT_ID: ${{ secrets.TEST_CLEAN_CLIENT_ID }}
Expand All @@ -75,12 +72,6 @@ jobs:
- name: Init GitHub CLI
run: |
echo ${{ secrets.GITHUB_TOKEN }} | gh auth login --with-token
- uses: azure/login@v1
with:
client-id: ${{secrets.DEVOPS_CLIENT_ID}}
tenant-id: ${{secrets.DEVOPS_TENANT_ID}}
subscription-id: ${{secrets.DEVOPS_SUB_ID}}
- name: bvt (dispatch)
id: bvt
Expand Down Expand Up @@ -198,12 +189,9 @@ jobs:
main:
name: ${{ matrix.test-case }}|${{ matrix.os }}|node ${{ matrix.node-version }}|${{ github.ref_name }}
needs: setup
environment: engineering
permissions:
id-token: write
contents: read
timeout-minutes: 50
env:
ADO_TOKEN: ${{ secrets.ADO_PAT }}
CI_ENABLED: true
NGROK_TOKEN: ${{ secrets.NGROK_TOKEN }}
TARGET_CLI_VERSION: ${{ needs.setup.outputs.target_cli_version }}
Expand Down Expand Up @@ -238,12 +226,6 @@ jobs:
matrix: ${{ fromJson(needs.setup.outputs.matrix) }}
runs-on: ${{ matrix.os }}
steps:
- uses: azure/login@v1
with:
client-id: ${{secrets.DEVOPS_CLIENT_ID}}
tenant-id: ${{secrets.DEVOPS_TENANT_ID}}
subscription-id: ${{secrets.DEVOPS_SUB_ID}}

- name: Set m365 account (unix)
if: matrix.os != 'windows-latest'
run: |
Expand Down Expand Up @@ -403,9 +385,9 @@ jobs:
- name: Get VSCode & chromedriver
working-directory: packages/tests
run: |
npx extest get-vscode --storage .test-resources --type stable --code_version .1.88.1
npx extest get-chromedriver --storage .test-resources --type stable --code_version .1.88.1
npx extest get-vscode --storage .test-resources --type stable --code_version 1.78.0
npx extest get-chromedriver --storage .test-resources --type stable --code_version 1.78.0
- name: Extract VSCode & chromedriver(unix)
if: matrix.os == 'ubuntu-latest'
working-directory: packages/tests
Expand All @@ -431,12 +413,6 @@ jobs:
run: | # rm -r -f ~/.fx/account
npx ts-node src/scripts/m365Login.ts -- '${{ env.M365_ACCOUNT_NAME }}' '${{ env.M365_ACCOUNT_PASSWORD }}'
- name: Azure Login(win)
if: matrix.os == 'windows-latest'
working-directory: packages/tests
run: |
npx ts-node src/scripts/azureLogin.ts -- '${{ env.AZURE_ACCOUNT_NAME }}' '${{ env.AZURE_ACCOUNT_PASSWORD }}'
- name: Build
working-directory: packages/tests
run: |
Expand All @@ -463,13 +439,13 @@ jobs:
sudo apt-get install xvfb
export DISPLAY=:99.0
Xvfb -ac :99 -screen 0 1920x1080x16 &
npx extest run-tests --storage .test-resources --extensions_dir .test-resources --type stable --code_version .1.88.1 --code_settings ./settings.json ./out/ui-test/**/${{ matrix.test-case }}.test.js
npx extest run-tests --storage .test-resources --extensions_dir .test-resources --type stable --code_version 1.88.1 --code_settings ./settings.json ./out/ui-test/**/${{ matrix.test-case }}.test.js
- name: Run UI Test(mac & win)
if: matrix.os != 'ubuntu-latest'
working-directory: packages/tests
run: |
npx extest run-tests --storage .test-resources --extensions_dir .test-resources --type stable --code_version .1.88.1 --code_settings ./settings.json ./out/ui-test/**/${{ matrix.test-case }}.test.js
npx extest run-tests --storage .test-resources --extensions_dir .test-resources --type stable --code_version 1.88.1 --code_settings ./settings.json ./out/ui-test/**/${{ matrix.test-case }}.test.js
- name: Upload test result json file
uses: actions/upload-artifact@v3
Expand Down

0 comments on commit b37d9b9

Please sign in to comment.