11name : Kinesis E2E Tests
22on :
3+ push :
4+ branches :
5+ - main
6+ - stable
7+ paths :
8+ - " packages/kinesis/**"
9+ - " .github/workflows/kinesis_e2e.yaml"
310 pull_request :
411 paths :
512 - " packages/kinesis/**"
613 - " .github/workflows/kinesis_e2e.yaml"
714 workflow_dispatch :
815
16+ defaults :
17+ run :
18+ shell : bash
19+
20+ # These permissions are needed to interact with GitHub's OIDC Token endpoint.
21+ permissions :
22+ id-token : write
23+ contents : read
24+
925concurrency :
1026 group : ${{ github.workflow }}-${{ github.ref }}
1127 cancel-in-progress : true
1228
1329jobs :
1430 kinesis-data-streams-e2e :
1531 runs-on : ubuntu-latest
16- permissions :
17- id-token : write
18- contents : read
32+ timeout-minutes : 30
1933 steps :
20- - uses : actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # 4.0.0
34+ - name : Git Checkout
35+ uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # 6.0.2
36+
37+ - name : Git Submodules
38+ run : git submodule update --init
39+
40+ - name : Setup Flutter
41+ uses : subosito/flutter-action@fd55f4c5af5b953cc57a2be44cb082c8f6635e8e # 2.21.0
2142 with :
22- persist-credentials : false
43+ cache : true
44+ channel : stable
2345
24- - uses : dart-lang/setup-dart@e630b99d28a3b71860378cafdc2a067c71107f94 # v1
46+ - name : Setup Dart
47+ uses : dart-lang/setup-dart@03a180dbe1de8ea7fb700663cbb7d24ca4bbe82c # main
2548 with :
2649 sdk : stable
2750
51+ - name : Install native sqlite3
52+ run : sudo apt-get update && sudo apt-get install -y libsqlite3-dev
53+
54+ - name : Setup aft
55+ run : dart pub global activate -spath packages/aft
56+
57+ - name : Bootstrap
58+ id : bootstrap
59+ timeout-minutes : 20
60+ run : aft bootstrap --fail-fast --include=aws_kinesis_datastreams --verbose
61+
2862 - name : Configure AWS credentials
2963 uses : aws-actions/configure-aws-credentials@04b98b3f9e85f563fb061be8751a0352327246b0 # 3.0.1
3064 with :
3872 KINESIS_E2E,${{ secrets.KINESIS_E2E_SECRET_ARN }}
3973 parse-json-secrets : true
4074
41- - name : Install native sqlite3
42- run : sudo apt-get update && sudo apt-get install -y libsqlite3-dev
43-
44- - name : Create pubspec overrides
45- working-directory : packages/kinesis/aws_kinesis_datastreams
46- run : |
47- cat > pubspec_overrides.yaml << 'EOF'
48- dependency_overrides:
49- amplify_core:
50- path: ../../amplify_core
51- amplify_db_common_dart:
52- path: ../../common/amplify_db_common_dart
53- amplify_foundation_dart:
54- path: ../../amplify_foundation/amplify_foundation_dart
55- amplify_foundation_dart_bridge:
56- path: ../../amplify_foundation/amplify_foundation_dart_bridge
57- amplify_lints:
58- path: ../../amplify_lints
59- aws_common:
60- path: ../../aws_common
61- aws_signature_v4:
62- path: ../../aws_signature_v4
63- smithy:
64- path: ../../smithy/smithy
65- smithy_aws:
66- path: ../../smithy/smithy_aws
67- EOF
68-
69- - name : Install dependencies
70- run : dart pub get
71- working-directory : packages/kinesis/aws_kinesis_datastreams
72-
7375 - name : Run E2E tests
7476 working-directory : packages/kinesis/aws_kinesis_datastreams
7577 env :
@@ -79,20 +81,55 @@ jobs:
7981 TEST_STREAM_NAME : ${{ env.KINESIS_E2E_STREAM_NAME }}
8082 run : dart test test/e2e/ --tags=e2e
8183
84+ - name : Log success/failure
85+ if : always()
86+ uses : ./.github/composite_actions/log_cw_metric_wrapper
87+ with :
88+ role-to-assume : ${{ secrets.AWS_ROLE_TO_ASSUME }}
89+ aws-region : ${{ secrets.AWS_REGION }}
90+
91+ job-status : ${{ job.status }}
92+ github-token : ${{ secrets.GITHUB_TOKEN }}
93+
94+ test-type : e2e
95+ working-directory : packages/kinesis/aws_kinesis_datastreams
96+
97+ framework : dart
98+ flutter-dart-channel : stable
99+ dart-compiler : vm
100+
82101 firehose-e2e :
83102 runs-on : ubuntu-latest
84- permissions :
85- id-token : write
86- contents : read
103+ timeout-minutes : 30
87104 steps :
88- - uses : actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # 4.0.0
105+ - name : Git Checkout
106+ uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # 6.0.2
107+
108+ - name : Git Submodules
109+ run : git submodule update --init
110+
111+ - name : Setup Flutter
112+ uses : subosito/flutter-action@fd55f4c5af5b953cc57a2be44cb082c8f6635e8e # 2.21.0
89113 with :
90- persist-credentials : false
114+ cache : true
115+ channel : stable
91116
92- - uses : dart-lang/setup-dart@e630b99d28a3b71860378cafdc2a067c71107f94 # v1
117+ - name : Setup Dart
118+ uses : dart-lang/setup-dart@03a180dbe1de8ea7fb700663cbb7d24ca4bbe82c # main
93119 with :
94120 sdk : stable
95121
122+ - name : Install native sqlite3
123+ run : sudo apt-get update && sudo apt-get install -y libsqlite3-dev
124+
125+ - name : Setup aft
126+ run : dart pub global activate -spath packages/aft
127+
128+ - name : Bootstrap
129+ id : bootstrap
130+ timeout-minutes : 20
131+ run : aft bootstrap --fail-fast --include=aws_amazon_firehose --verbose
132+
96133 - name : Configure AWS credentials
97134 uses : aws-actions/configure-aws-credentials@04b98b3f9e85f563fb061be8751a0352327246b0 # 3.0.1
98135 with :
@@ -106,34 +143,6 @@ jobs:
106143 KINESIS_E2E,${{ secrets.KINESIS_E2E_SECRET_ARN }}
107144 parse-json-secrets : true
108145
109- - name : Install native sqlite3
110- run : sudo apt-get update && sudo apt-get install -y libsqlite3-dev
111-
112- - name : Create pubspec overrides
113- working-directory : packages/kinesis/aws_amazon_firehose
114- run : |
115- cat > pubspec_overrides.yaml << 'EOF'
116- dependency_overrides:
117- amplify_core:
118- path: ../../amplify_core
119- amplify_foundation_dart:
120- path: ../../amplify_foundation/amplify_foundation_dart
121- amplify_foundation_dart_bridge:
122- path: ../../amplify_foundation/amplify_foundation_dart_bridge
123- aws_common:
124- path: ../../aws_common
125- aws_signature_v4:
126- path: ../../aws_signature_v4
127- smithy:
128- path: ../../smithy/smithy
129- smithy_aws:
130- path: ../../smithy/smithy_aws
131- EOF
132-
133- - name : Install dependencies
134- run : dart pub get
135- working-directory : packages/kinesis/aws_amazon_firehose
136-
137146 - name : Run E2E tests
138147 working-directory : packages/kinesis/aws_amazon_firehose
139148 env :
@@ -142,3 +151,20 @@ jobs:
142151 TEST_REGION : ${{ secrets.AWS_REGION }}
143152 TEST_DELIVERY_STREAM_NAME : ${{ env.KINESIS_E2E_DELIVERY_STREAM_NAME }}
144153 run : dart test test/e2e/ --tags=e2e
154+
155+ - name : Log success/failure
156+ if : always()
157+ uses : ./.github/composite_actions/log_cw_metric_wrapper
158+ with :
159+ role-to-assume : ${{ secrets.AWS_ROLE_TO_ASSUME }}
160+ aws-region : ${{ secrets.AWS_REGION }}
161+
162+ job-status : ${{ job.status }}
163+ github-token : ${{ secrets.GITHUB_TOKEN }}
164+
165+ test-type : e2e
166+ working-directory : packages/kinesis/aws_amazon_firehose
167+
168+ framework : dart
169+ flutter-dart-channel : stable
170+ dart-compiler : vm
0 commit comments