File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -324,7 +324,9 @@ jobs:
324324 cdk-lib-version : ${{ needs.resolve_inputs.outputs.cdk_lib_version }}
325325 - name : Check if any E2E tests should run
326326 id : check
327- run : echo "run_e2e=$(npx tsx scripts/do_include_e2e.ts)" >> "$GITHUB_OUTPUT"
327+ run : |
328+ run_e2e=$(npx tsx scripts/do_include_e2e.ts)
329+ echo "run_e2e=$run_e2e" >> "$GITHUB_OUTPUT"
328330 - run : echo run_e2e set to ${{ steps.check.outputs.run_e2e }}
329331 - name : Check if Package Manager E2E tests should be included
330332 id : check_package_manager
Original file line number Diff line number Diff line change @@ -17,6 +17,16 @@ const prHasRunE2ELabel = async () => {
1717 const hasRunE2ELabel = prInfo . labels . some (
1818 ( label ) => label . name === 'run-e2e' ,
1919 ) ;
20+
21+ if (
22+ hasRunE2ELabel &&
23+ prInfo . head ?. repo ?. full_name !== 'aws-amplify/amplify-backend'
24+ ) {
25+ throw new Error (
26+ 'PR must be opened from a branch in aws-amplify/amplify-backend repository when running e2e tests.' ,
27+ ) ;
28+ }
29+
2030 return hasRunE2ELabel ;
2131} ;
2232
You can’t perform that action at this time.
0 commit comments