-
-
Notifications
You must be signed in to change notification settings - Fork 116
49 lines (45 loc) · 1.41 KB
/
main.yml
File metadata and controls
49 lines (45 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: CI
on:
pull_request_target:
branches: [main]
types: [opened, synchronize, reopened]
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
environment: external-pr-check
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Use latest Node LTS
uses: actions/setup-node@v3
with:
node-version: 'lts/*'
- name: Install Dependencies
run: npm install
- name: Lint
run: npm run lint
- name: Build
run: npm run build
- name: Unit Tests
run: npm run test:unit
- name: Integration Tests
run: npm run test:int
env:
CI: 'true'
AZURE_DEVOPS_ORG_URL: ${{ secrets.AZURE_DEVOPS_ORG_URL }}
AZURE_DEVOPS_PAT: ${{ secrets.AZURE_DEVOPS_PAT }}
AZURE_DEVOPS_DEFAULT_PROJECT: ${{ secrets.AZURE_DEVOPS_DEFAULT_PROJECT }}
AZURE_DEVOPS_DEFAULT_REPOSITORY: eShopOnWeb
AZURE_DEVOPS_AUTH_METHOD: pat
- name: E2E Tests
run: npm run test:e2e
env:
CI: 'true'
AZURE_DEVOPS_ORG_URL: ${{ secrets.AZURE_DEVOPS_ORG_URL }}
AZURE_DEVOPS_PAT: ${{ secrets.AZURE_DEVOPS_PAT }}
AZURE_DEVOPS_DEFAULT_PROJECT: ${{ secrets.AZURE_DEVOPS_DEFAULT_PROJECT }}
AZURE_DEVOPS_DEFAULT_REPOSITORY: eShopOnWeb
AZURE_DEVOPS_AUTH_METHOD: pat