---
version: '3'

tasks:
  actions:test:
    deps:
      - :install:software:act
      - :install:software:docker
    desc: Locally test the on-push GitHub Action event (only works for Linux containers)
    hide:
      sh: '! test -d .github/workflows'
    summary: |
      # Test GitHub Actions

      This task ensures Docker and Act are installed. It then uses Act to locally
      test Linux-based on-push GitHub Action events.

      See [Act's README.md](https://github.com/nektos/act) for more information.
    log:
      error: Error encountered while testing GitHub Actions locally with `act`
      start: Testing GitHub Actions locally with `act`
      success: Completed local GitHub Actions test
    cmds:
      - act
