Merge pull request #21 from threeal/audit-test

Audit Tests
This commit is contained in:
Alfi Maulana 2023-01-13 21:08:56 +07:00 committed by GitHub
commit 8468e0d7d2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,11 +3,11 @@ on:
workflow_dispatch: workflow_dispatch:
push: push:
jobs: jobs:
use-action: default-usage:
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}-latest
strategy: strategy:
matrix: matrix:
os: [windows-latest, ubuntu-latest, macos-latest] os: [windows, ubuntu, macos]
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v3.3.0 uses: actions/checkout@v3.3.0
@ -19,9 +19,9 @@ jobs:
uses: ./ uses: ./
- name: Run build result - name: Run build result
run: ${{ matrix.os == 'windows-latest' && 'build\Debug\hello_world.exe' || 'build/hello_world' }} run: ${{ matrix.os == 'windows' && 'build\Debug\hello_world.exe' || 'build/hello_world' }}
use-action-with-specified-dir: specified-dir-usage:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout repository - name: Checkout repository
@ -39,26 +39,11 @@ jobs:
- name: Check if the default build directory does not exist - name: Check if the default build directory does not exist
run: test ! -d build run: test ! -d build
use-action-with-specified-targets: specified-compiler-usage:
runs-on: ubuntu-latest runs-on: ${{ matrix.os }}-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3.3.0
- name: Use this action with specified targets
uses: ./
with:
source-dir: test
targets: test_c test_cpp
- name: Run build result
run: build/test_c && build/test_cpp
use-action-with-specified-compiler:
runs-on: ${{ matrix.os }}
strategy: strategy:
matrix: matrix:
os: [windows-latest, ubuntu-latest, macos-latest] os: [windows, ubuntu, macos]
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v3.3.0 uses: actions/checkout@v3.3.0
@ -76,11 +61,11 @@ jobs:
- name: Run build result - name: Run build result
run: build/test_c && build/test_cpp run: build/test_c && build/test_cpp
use-action-with-specified-generator: specified-generator-usage:
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}-latest
strategy: strategy:
matrix: matrix:
os: [windows-latest, ubuntu-latest, macos-latest] os: [windows, ubuntu, macos]
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v3.3.0 uses: actions/checkout@v3.3.0