Skip to content

TestDriver.ai

TestDriver.ai #141

Workflow file for this run

name: TestDriver.ai
permissions:
actions: read
contents: read
statuses: write
pull-requests: write
on:
push:
branches: ["main"]
pull_request:
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
jobs:
gather-test-files:
name: Gather Test Files
runs-on: ubuntu-latest
outputs:
test_files: ${{ steps.test_list.outputs.files }}
steps:
- name: Check out repository
uses: actions/checkout@v2
with:
ref: ${{ github.event.ref }}
- name: Find all test files and extract filenames
id: test_list
run: |
FILES=$(ls ./testdriver/*.yaml)
FILENAMES=$(basename -a $FILES)
FILES_JSON=$(echo "$FILENAMES" | jq -R -s -c 'split("\n")[:-1]')
echo "::set-output name=files::$FILES_JSON"
test:
needs: gather-test-files
runs-on: ubuntu-latest
strategy:
matrix:
os: [linux, windows]
test: ${{ fromJson(needs.gather-test-files.outputs.test_files) }}
fail-fast: false
name: ${{ matrix.os }} - ${{ matrix.test }}
steps:
- name: Check out repository
uses: actions/checkout@v2
- uses: testdriverai/action@main
with:
os: ${{ contains(matrix.os, 'windows') && 'windows' || 'linux' }}
version: "5.5.5"
prerun: |
exit
key: ${{ secrets.TD_API_KEY }}
prompt: |
1. /run testdriver/${{ matrix.test }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
FORCE_COLOR: "3"
WEBSITE_URL: "example.com"