Skip to content

Commit

Permalink
ci: separate codebuild & cci differences (#12751)
Browse files Browse the repository at this point in the history
  • Loading branch information
awsluja authored Jun 6, 2023
1 parent fcfebe1 commit 756db0f
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
13 changes: 12 additions & 1 deletion .circleci/local_publish_helpers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -267,8 +267,19 @@ function setAwsAccountCredentials {
useChildAccountCredentials
fi
}

function runE2eTest {
FAILED_TEST_REGEX_FILE="./amplify-e2e-reports/amplify-e2e-failed-test.txt"

if [ -f $FAILED_TEST_REGEX_FILE ]; then
# read the content of failed tests
failedTests=$(<$FAILED_TEST_REGEX_FILE)
yarn e2e --forceExit --no-cache --maxWorkers=4 $TEST_SUITE -t "$failedTests"
else
yarn e2e --forceExit --no-cache --maxWorkers=4 $TEST_SUITE
fi
}

function runE2eTestCb {
_setupCoverage
FAILED_TEST_REGEX_FILE="./amplify-e2e-reports/amplify-e2e-failed-test.txt"

Expand Down
2 changes: 1 addition & 1 deletion codebuild_specs/scripts-windows/run-e2e-windows.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ cd packages/amplify-e2e-tests

_loadTestAccountCredentials

retry runE2eTest
retry runE2eTestCb
2 changes: 1 addition & 1 deletion shared-scripts.sh
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ function _runE2ETestsLinux {
amplify version
cd packages/amplify-e2e-tests
_loadTestAccountCredentials
retry runE2eTest
retry runE2eTestCb
}
function _unassumeTestAccountCredentials {
echo "Unassume Role"
Expand Down

0 comments on commit 756db0f

Please sign in to comment.