Published on

GitHub Actions for Altwalker

How to crate a GitHub Actions workflow to run your AltWalker tests.

This tutorial should help you setup a GitHub workflow to automatically run your AltWalker tests.

Create a workflow for your AltWalker tests

  1. Create a new file in your project at .github/workflows/deploy.yml and paste in the YAML below.

    name: AltWalker Tests
    on: [push]
        runs-on: ubuntu-latest
        - uses: actions/checkout@v3
        - name: Setup AltWalker
          uses: altwalker/setup-altwalker@v1
        - name: Check the models
          run: altwalker check -m models/default.json "random(vertex_coverage(100))"
          shell: bash
        - name: Verify the code
          run: altwalker verify tests -m models/default.json
          shell: bash
        - name: Run the tests
          run: altwalker online tests -m models/default.json "random(vertex_coverage(100))"
          shell: bash
        - name: Generate a test sequence
          run: altwalker offline -m models/default.json "random(vertex_coverage(100))" -f steps/steps.json
          shell: bash
        - name: Run a pre-generated sequence
          run: altwalker walk tests steps/steps.json
          shell: bash
        - name: Archive log files
          uses: actions/upload-artifact@v2
          if: ${{ always() }}
            name: logs
            path: '*.log'
  2. On GitHub, go to your repository’s Settings tab and find the Pages section of the settings.

  3. Choose GitHub Actions as the Source of your site and press Save.

  4. Commit the new workflow file and push it to GitHub.

See also

GitHub Actions for Hugo

This tutorial should help you setup and deploy an Hugo site to GitHub Pages by using GitHub Actions to automatically build and deploy your site.