docs(seo): generate llms-full.txt with full docs at build time #39
This file contains hidden or 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 action | |
| on: | |
| pull_request: | |
| paths: | |
| - 'action.yml' | |
| - 'install.sh' | |
| - '.github/workflows/test-action.yml' | |
| push: | |
| branches: | |
| - main | |
| concurrency: | |
| group: test-action-${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
| permissions: | |
| contents: read | |
| jobs: | |
| test-action: | |
| name: "Install via action - ${{ matrix.os }}" | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 10 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install bashunit via the action | |
| id: bashunit | |
| uses: ./ | |
| with: | |
| version: latest | |
| directory: vendor/bashunit | |
| - name: Verify the binary is installed and runnable | |
| env: | |
| BASHUNIT_PATH: ${{ steps.bashunit.outputs.path }} | |
| BASHUNIT_INSTALLED_VERSION: ${{ steps.bashunit.outputs.version }} | |
| run: | | |
| set -euo pipefail | |
| test -x "$BASHUNIT_PATH" | |
| test -n "$BASHUNIT_INSTALLED_VERSION" | |
| # add-to-path defaults to true, so "bashunit" resolves on PATH | |
| bashunit --version | |
| run-via-args: | |
| name: "Run via args input" | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Write a passing and a failing sample test | |
| run: | | |
| mkdir -p sample_tests | |
| printf 'function test_passes() { assert_same "1" "1"; }\n' > sample_tests/pass_test.sh | |
| printf 'function test_fails() { assert_same "1" "2"; }\n' > sample_tests/fail_test.sh | |
| - name: Run only the passing test via args (step should pass) | |
| uses: ./ | |
| with: | |
| directory: vendor/bashunit | |
| args: sample_tests/pass_test.sh | |
| - name: Run the failing test via args (expected to fail the step) | |
| id: failing | |
| continue-on-error: true | |
| uses: ./ | |
| with: | |
| directory: vendor/bashunit | |
| add-to-path: 'false' | |
| args: sample_tests/fail_test.sh | |
| - name: Assert the failing run actually executed and failed | |
| env: | |
| OUTCOME: ${{ steps.failing.outcome }} | |
| run: | | |
| set -euo pipefail | |
| # If args were ignored (install-only), the step would have succeeded. | |
| test "$OUTCOME" = "failure" |