21
21
permissions :
22
22
checks : write
23
23
name : Run tests and create NuGet package
24
- outputs :
25
- nupkg-filename : ${{ steps.dotnet-pack.outputs.nupkg-filename }}
26
24
steps :
27
25
- name : Checkout git repository
28
26
uses : actions/checkout@v3
43
41
run : dotnet build --no-restore
44
42
- name : Run tests
45
43
run : dotnet test --no-build
46
- id : dotnet-test
47
44
- name : Upload received files from failing tests
48
45
uses : actions/upload-artifact@v3
49
46
if : failure()
@@ -78,13 +75,12 @@ jobs:
78
75
coverage-reports : coverage/*/coverage.cobertura.xml
79
76
- name : Create NuGet package
80
77
run : dotnet pack --no-build --output .
81
- id : dotnet-pack
82
78
- name : Upload NuGet package artifact
83
79
if : matrix.os == 'ubuntu-latest'
84
80
uses : actions/upload-artifact@v3
85
81
with :
86
- name : ${{ steps.dotnet-pack.outputs.nupkg-filename }}
87
- path : ${{ steps.dotnet-pack.outputs. nupkg-filename }}
82
+ name : NuGet package
83
+ path : " *. nupkg"
88
84
- name : Run mutation tests and upload report to Stryker dashboard
89
85
env :
90
86
STRYKER_DASHBOARD_API_KEY : ${{ secrets.STRYKER_DASHBOARD_API_KEY }}
@@ -114,7 +110,7 @@ jobs:
114
110
- name : Download NuGet package artifact
115
111
uses : actions/download-artifact@v3
116
112
with :
117
- name : ${{ needs. package.outputs.nupkg-filename }}
113
+ name : NuGet package
118
114
- name : Download release notes artifact
119
115
uses : actions/download-artifact@v3
120
116
with :
@@ -126,4 +122,4 @@ jobs:
126
122
body_path : ReleaseNotes.md
127
123
prerelease : ${{ contains(github.ref_name, '-') }}
128
124
- name : Publish NuGet package on nuget.org
129
- run : dotnet nuget push ${{ needs.package.outputs. nupkg-filename }} --source https://api.nuget.org/v3/index.json --api-key "${{ secrets.NUGET_API_KEY }}"
125
+ run : dotnet nuget push "*. nupkg" --source https://api.nuget.org/v3/index.json --api-key "${{ secrets.NUGET_API_KEY }}"
0 commit comments