Skip to content

Add GITHUB_DOT_COM_TOKEN #656

Add GITHUB_DOT_COM_TOKEN

Add GITHUB_DOT_COM_TOKEN #656

Workflow file for this run

name: Test terraform-check
on:
- pull_request
jobs:
no_changes:
runs-on: ubuntu-latest
name: No changes
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Check
uses: ./terraform-check
id: check
with:
path: tests/workflows/test-check/no_changes
- name: Check failure-reason
run: |
if [[ "${{ steps.check.outputs.failure-reason }}" != "" ]]; then
echo "::error:: failure-reason not set correctly"
exit 1
fi
plan_change_comment:
runs-on: ubuntu-latest
name: Changes
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Check
uses: ./terraform-check
continue-on-error: true
id: check
with:
path: tests/workflows/test-check/changes
- name: Check failure-reason
run: |
if [[ "${{ steps.check.outcome }}" != "failure" ]]; then
echo "Check did not fail correctly"
exit 1
fi
if [[ "${{ steps.check.outputs.failure-reason }}" != "changes-to-apply" ]]; then
echo "::error:: failure-reason not set correctly"
exit 1
fi