Env var prefix fix #42
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: Test | |
on: | |
workflow_dispatch: | |
push: | |
paths: | |
- "**/*.js" | |
- "action.yml" | |
- ".github/workflows/test.yml" | |
jobs: | |
setup_job: | |
runs-on: ubuntu-latest | |
container: orgflow/cli:2.x | |
name: Setup | |
outputs: | |
stack-name: ${{ steps.create_stack.outputs.stack-name }} | |
steps: | |
- id: create_stack | |
name: Create temporary stack | |
run: | | |
mkdir /tmp/$STACKNAME | |
git init --bare -b main /tmp/$STACKNAME | |
orgflow stack:create --name=$STACKNAME --gitRepoUrl=/tmp/$STACKNAME --username='${{ secrets.SALESFORCE_USERNAME }}' --password='${{ secrets.SALESFORCE_PASSWORD }}' --licenseKey=${{ secrets.ORGFLOW_LICENSEKEY }} --acceptEula | |
echo "stack-name=$STACKNAME" >> $GITHUB_OUTPUT | |
env: | |
STACKNAME: TestStack_${{ github.run_id }}_${{ github.run_number }} | |
test_job: | |
runs-on: ${{ matrix.image }} | |
name: Test action | |
needs: setup_job | |
strategy: | |
matrix: | |
image: [ubuntu-latest, macos-latest, windows-latest] | |
version: [1, 2] | |
fail-fast: false | |
steps: | |
- name: Checkout source | |
uses: actions/checkout@v3 | |
- name: Set up OrgFlow | |
uses: ./ | |
id: setup | |
with: | |
version: ${{ matrix.version }} | |
license-key: ${{ secrets.ORGFLOW_LICENSEKEY }} | |
salesforce-username: ${{ secrets.SALESFORCE_USERNAME }} | |
salesforce-password: ${{ secrets.SALESFORCE_PASSWORD }} | |
git-username: DimitriusWoodward # Bogus | |
git-password: tMfxyRCtnulUxXZl # Bogus | |
stack-name: ${{ needs.setup_job.outputs.stack-name }} | |
diag-artifact-name: orgflow_diag_${{ matrix.image }}_${{ github.run_attempt }} | |
env: | |
ORGFLOW__ACCEPTEULA: "true" | |
- name: Print outputs | |
run: | | |
echo "Version: ${{ steps.setup.outputs.version }}" | |
echo "Encryption key: ${{ steps.setup.outputs.encryption-key }}" | |
- name: Test persisted config | |
run: | | |
orgflow env:list | |
teardown_job: | |
runs-on: ubuntu-latest | |
container: orgflow/cli:2.x | |
name: Teardown | |
needs: [setup_job, test_job] | |
if: ${{ always() }} | |
steps: | |
- name: Delete temporary stack | |
run: | | |
orgflow stack:delete --name=$STACKNAME --licenseKey=${{ secrets.ORGFLOW_LICENSEKEY }} --acceptEula --noConfirm | |
env: | |
STACKNAME: ${{ needs.setup_job.outputs.stack-name }} |