-
Notifications
You must be signed in to change notification settings - Fork 421
62 lines (56 loc) · 1.71 KB
/
run-e2e-tests.yml
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
50
51
52
53
54
55
56
57
58
59
60
61
62
name: Run end-to-end tests
on:
workflow_dispatch:
push:
branches: [develop, v2]
paths:
- "aws_lambda_powertools/**"
- "tests/e2e/**"
- "pyproject.toml"
- "poetry.lock"
- "mypy.ini"
- "parallel_run_e2e.py"
# Maintenance: Add support for triggering on `run-e2e` label
# and enforce repo origin to prevent abuse
env:
AWS_DEFAULT_REGION: us-east-1
concurrency: e2e
jobs:
run:
runs-on: aws-lambda-powertools_ubuntu-latest_8-core
permissions:
id-token: write # needed to request JWT with GitHub's OIDC Token endpoint. docs: https://bit.ly/3MNgQO9
contents: read
strategy:
fail-fast: false # needed so if a version fails, the others will still be able to complete and cleanup
matrix:
version: ["3.7", "3.8", "3.9", "3.10"]
if: ${{ github.actor != 'dependabot[bot]' }}
steps:
- name: "Checkout"
uses: actions/checkout@v3
- name: Install poetry
run: pipx install poetry
- name: "Use Python"
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.version }}
architecture: "x64"
cache: "poetry"
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: "16.12"
- name: Install CDK CLI
run: |
npm install
npx cdk --version
- name: Install dependencies
run: make dev
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@e1e17a757e536f70e52b5a12b2e8d1d1c60e04ef
with:
role-to-assume: ${{ secrets.AWS_TEST_ROLE_ARN }}
aws-region: ${{ env.AWS_DEFAULT_REGION }}
- name: Test
run: make e2e-test