forked from ThreeMammals/Ocelot
-
Notifications
You must be signed in to change notification settings - Fork 0
149 lines (146 loc) · 5.3 KB
/
Copy pathdevelop.yml
File metadata and controls
149 lines (146 loc) · 5.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
name: Develop
on:
push:
branches:
- develop
# - 'release/**' # for testing purposes
jobs:
build-windows:
runs-on: windows-latest
env:
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup .NET 9
uses: actions/setup-dotnet@v5
with:
dotnet-version: 9.x
cache: true
cache-dependency-path: |
samples/**/packages.lock.json
src/**/packages.lock.json
test/**/packages.lock.json
- name: .NET Info
run: dotnet --info
- name: Add DNS-records
run: ./.github/steps/windows.add-dns-records.ps1
- name: Install certificate
run: ./.github/steps/windows.install-certificate.ps1
- name: Restore
run: dotnet restore --locked-mode ./Ocelot.Release.sln
- name: Build
run: dotnet build --no-restore ./Ocelot.Release.sln --framework net9.0
- name: Unit Tests
run: dotnet test --no-restore --no-build --verbosity minimal --framework net9.0 ./test/Ocelot.UnitTests/Ocelot.UnitTests.csproj
- name: Acceptance Tests
run: dotnet test --no-restore --no-build --verbosity minimal --framework net9.0 ./test/Ocelot.AcceptanceTests/Ocelot.AcceptanceTests.csproj
build-macos:
needs: build-windows
runs-on: macos-latest
env:
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
steps:
- name: Checkout
uses: actions/checkout@v5
- name: SH-scripts executable
run: |
chmod +x .github/steps/*.sh
ls -l .github/steps/*.sh
- name: Setup .NET 9
uses: actions/setup-dotnet@v5
with:
dotnet-version: 9.x
cache: true
cache-dependency-path: |
samples/**/packages.lock.json
src/**/packages.lock.json
test/**/packages.lock.json
- name: .NET Info
run: dotnet --info
- name: Add DNS-records
run: ./.github/steps/macos.add-dns-records.sh
- name: Install certificate
run: ./.github/steps/macos.install-certificate.sh
- name: Restore
run: dotnet restore --locked-mode ./Ocelot.Release.sln
- name: Build
run: dotnet build --no-restore ./Ocelot.Release.sln --framework net9.0
- name: Unit Tests
run: dotnet test --no-restore --no-build --verbosity minimal --framework net9.0 ./test/Ocelot.UnitTests/Ocelot.UnitTests.csproj
- name: Acceptance Tests
run: dotnet test --no-restore --no-build --verbosity minimal --framework net9.0 ./test/Ocelot.AcceptanceTests/Ocelot.AcceptanceTests.csproj
build-linux:
needs: build-macos
strategy:
matrix:
dotnet-version: [ '8', '9' ]
runs-on: ubuntu-latest
env:
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
steps:
- name: Checkout
uses: actions/checkout@v5
- name: SH-scripts executable
run: |
chmod +x .github/steps/*.sh
ls -l .github/steps/*.sh
- name: Check .NET ${{ matrix.dotnet-version }}
id: check-dotnet
run: ./.github/steps/check-dotnet.sh ${{ matrix.dotnet-version }}
- name: Setup .NET ${{ matrix.dotnet-version }}
# if: env.DOTNET${{ matrix.dotnet-version }}_installed == 'false'
uses: actions/setup-dotnet@v5
with:
dotnet-version: ${{ matrix.dotnet-version }}.x
cache: true
cache-dependency-path: |
samples/**/packages.lock.json
src/**/packages.lock.json
test/**/packages.lock.json
- name: .NET Info
run: dotnet --info
- name: Add DNS-records
run: ./.github/steps/ubuntu.add-dns-records.sh
- name: Install certificate
run: ./.github/steps/ubuntu.install-certificate.sh
- name: Restore
run: dotnet restore --locked-mode ./Ocelot.Release.sln
- name: Build
run: dotnet build --no-restore ./Ocelot.Release.sln --framework net${{ matrix.dotnet-version }}.0
- name: Unit Tests
run: dotnet test --no-restore --no-build --verbosity minimal --framework net${{ matrix.dotnet-version }}.0 ./test/Ocelot.UnitTests/Ocelot.UnitTests.csproj
- name: Acceptance Tests
run: dotnet test --no-restore --no-build --verbosity minimal --framework net${{ matrix.dotnet-version }}.0 ./test/Ocelot.AcceptanceTests/Ocelot.AcceptanceTests.csproj
build-cake:
needs: build-linux
runs-on: ubuntu-latest
env:
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: SH-scripts executable
run: chmod +x .github/steps/*.sh
- name: Setup .NET 9
uses: actions/setup-dotnet@v5
with:
dotnet-version: 9.x
cache: true
cache-dependency-path: |
samples/**/packages.lock.json
src/**/packages.lock.json
test/**/packages.lock.json
- name: Cake Build
uses: cake-build/cake-action@v3
with:
target: UnitTests # LatestFramework
- name: Prepare Coveralls
run: ./.github/steps/prepare-coveralls.sh
- name: Coveralls
if: env.COVERALLS_coverage_file_exists == 'true'
uses: coverallsapp/github-action@v2
with:
file: ${{ env.COVERALLS_coverage_file }}