Skip to content

Commit 3e725e7

Browse files
committed
bump workflows/test-v1.3.1
1 parent 8c8ee8b commit 3e725e7

File tree

2 files changed

+59
-4
lines changed

2 files changed

+59
-4
lines changed

.github/workflows/test-packages.yml

Lines changed: 32 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,41 @@ on:
1313
description: "The project name to run the test."
1414
required: false
1515
type: string
16+
1617
os:
17-
description: "The OS label which run the test on. (ex: ubuntu-latest, windows-latest, macos-latest)"
18+
description: "The OS label which run the test on. (ex: ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest)"
1819
required: false
1920
type: string
21+
2022
verbose:
2123
description: "If true, enables verbose output."
2224
required: false
2325
type: boolean
2426
default: false
2527

28+
dotnet_test_options_verbosity_level:
29+
description: "The argument to be set to the `--verbosity <LEVEL>` option of the `dotnet test` command. <LEVEL> := q[uiet], m[inimal], n[ormal], d[etailed], diag[nostic]"
30+
required: false
31+
type: string
32+
33+
dotnet_test_options_framework:
34+
description: "The argument to be set to the `--framework <FRAMEWORK>` option of the `dotnet test` command."
35+
required: false
36+
type: string
37+
38+
dotnet_test_options_filter_expression:
39+
description: "The argument to be set to the `--filter <EXPRESSION>` option of the `dotnet test` command."
40+
required: false
41+
type: string
42+
2643
jobs:
2744
prerequisites:
2845
runs-on: ubuntu-latest
2946
outputs:
47+
os: ${{ steps.input-prerequisites.outputs.os }}
3048
verbose: ${{ steps.input-prerequisites.outputs.verbose }}
49+
env:
50+
RUNS_ON_OS_LIST_DEFAULT: 'ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest'
3151
steps:
3252
- name: Delay until the package is published
3353
run: |
@@ -40,24 +60,33 @@ jobs:
4060
- name: Determine prerequisites
4161
id: input-prerequisites
4262
run: |
63+
if [ -z '${{ github.event.inputs.os }}' ]; then
64+
echo "os=${RUNS_ON_OS_LIST_DEFAULT}" >> $GITHUB_OUTPUT
65+
else
66+
echo 'os=${{ github.event.inputs.os }}' >> $GITHUB_OUTPUT
67+
fi
68+
4369
if [ '${{ github.event.inputs.verbose }}' = 'true' ]; then
4470
echo 'verbose=true' >> $GITHUB_OUTPUT
4571
else
4672
echo 'verbose=false' >> $GITHUB_OUTPUT
4773
fi
4874
4975
run-test:
50-
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test-v1.2.1
76+
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test-v1.3.1
5177
needs: prerequisites
5278
with:
5379
project: ${{ github.event.inputs.project }}
54-
os: ${{ github.event.inputs.os }}
80+
os: ${{ needs.prerequisites.outputs.os }}
5581
extra_options_common: '/p:TestReleasedPackage=true'
5682
verbose: ${{ fromJSON(needs.prerequisites.outputs.verbose) }}
5783
path_proj_install_project_assets: "eng/InstallProjectAssets.proj"
5884
dotnet_sdk_version: '8.0.100'
5985
timeout_minutes_test_job: 10
6086
timeout_hang: "[ {'OS':'windows','Timeout':'6min'}, {'OS':'macos','Timeout':'3min'}, {'OS':'','Timeout':'1min'} ]"
6187
timeout_vstest_connection: "[ {'OS':'windows','Timeout':360}, {'OS':'macos','Timeout':180}, {'OS':'','Timeout':60} ]"
88+
dotnet_test_options_verbosity_level: ${{ github.event.inputs.dotnet_test_options_verbosity_level }}
89+
dotnet_test_options_framework: ${{ github.event.inputs.dotnet_test_options_framework }}
90+
dotnet_test_options_filter_expression: ${{ github.event.inputs.dotnet_test_options_filter_expression }}
6291
secrets:
6392
token_repo: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/test.yml

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,38 @@ on:
2626
description: "The project name to run the test."
2727
required: false
2828
type: string
29+
2930
os:
3031
description: "The OS label which run the test on. (ex: ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest)"
3132
required: false
3233
type: string
34+
3335
verbose:
3436
description: "If true, enables verbose output."
3537
required: false
3638
type: boolean
3739
default: false
3840

41+
extra_options_common:
42+
description: "The common extra options to be set on running the `dotnet restore/build/test` command."
43+
required: false
44+
type: string
45+
46+
dotnet_test_options_verbosity_level:
47+
description: "The argument to be set to the `--verbosity <LEVEL>` option of the `dotnet test` command. <LEVEL> := q[uiet], m[inimal], n[ormal], d[etailed], diag[nostic]"
48+
required: false
49+
type: string
50+
51+
dotnet_test_options_framework:
52+
description: "The argument to be set to the `--framework <FRAMEWORK>` option of the `dotnet test` command."
53+
required: false
54+
type: string
55+
56+
dotnet_test_options_filter_expression:
57+
description: "The argument to be set to the `--filter <EXPRESSION>` option of the `dotnet test` command."
58+
required: false
59+
type: string
60+
3961
jobs:
4062
prerequisites:
4163
runs-on: ubuntu-latest
@@ -61,7 +83,7 @@ jobs:
6183
fi
6284
6385
run-test:
64-
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test-v1.2.1
86+
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test-v1.3.1
6587
needs: prerequisites
6688
with:
6789
project: ${{ github.event.inputs.project }}
@@ -72,5 +94,9 @@ jobs:
7294
timeout_minutes_test_job: 10
7395
timeout_hang: "[ {'OS':'windows','Timeout':'6min'}, {'OS':'macos','Timeout':'3min'}, {'OS':'','Timeout':'1min'} ]"
7496
timeout_vstest_connection: "[ {'OS':'windows','Timeout':360}, {'OS':'macos','Timeout':180}, {'OS':'','Timeout':60} ]"
97+
extra_options_common: ${{ github.event.inputs.extra_options_common }}
98+
dotnet_test_options_verbosity_level: ${{ github.event.inputs.dotnet_test_options_verbosity_level }}
99+
dotnet_test_options_framework: ${{ github.event.inputs.dotnet_test_options_framework }}
100+
dotnet_test_options_filter_expression: ${{ github.event.inputs.dotnet_test_options_filter_expression }}
75101
secrets:
76102
token_repo: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)