fix syntax 6 #11
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: e2e-tests | |
on: | |
push: | |
branches-ignore: [main] | |
workflow_dispatch: | |
jobs: | |
e2e-test-job: | |
runs-on: ubuntu-latest | |
env: | |
DEVHUB_USERNAME: ${{ secrets.PATCH_DEVHUB_USERNAME }} | |
DEVHUB_AUTH: ${{ secrets.PATCH_DEVHUB_AUTH }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: '20' | |
- run: | | |
echo 'y' | npm install @salesforce/cli --global | |
sf --version | |
echo 'y' | sf plugins install https://github.com/forcedotcom/commerce-on-lightning.git#develop | |
echo 'y' | sf plugins install shane-sfdx-plugins | |
echo ${{ env.DEVHUB_AUTH }} > authFile | |
sf force auth sfdxurl store -f 'authFile' | |
export SCRATCH_ORG_ID=`date +%Y%m%d-%H%M%S` | |
export SCRATCH_ORG_ALIAS="gworkflow_$SCRATCH_ORG_ID" | |
export SCRATCH_ORG_USERNAME="[email protected]" | |
echo "Scratch org name is going to be $SCRATCH_ORG_USERNAME" | |
LAST_SCRATCH_ORG=`sf data query --query "SELECT Id FROM ActiveScratchOrg WHERE SignupUsername LIKE 'gworkflow_%' LIMIT 1" -u ${{ env.DEVHUB_USERNAME }} | egrep '[0-9a-zA-Z]{18}'` | |
echo "Last scratch org is $LAST_SCRATCH_ORG" | |
sf data record delete -o ${{ env.DEVHUB_USERNAME }} -s ActiveScratchOrg -i $LAST_SCRATCH_ORG -u ${{ env.DEVHUB_USERNAME }} | egrep '[0-9a-zA-Z]{18}'` || true) | |
sf commerce scratchorg create -u "$SCRATCH_ORG_USERNAME" -a "$SCRATCH_ORG_ALIAS" -v ${{ env.DEVHUB_USERNAME }} |