Added workflow to automatically build and test the server
This commit is contained in:
parent
a34bf6710c
commit
0c4d946c9e
|
@ -212,7 +212,6 @@ dotnet_style_qualification_for_field = false:silent
|
|||
dotnet_style_parentheses_in_other_operators = never_if_unnecessary:silent
|
||||
dotnet_style_qualification_for_event = false:silent
|
||||
dotnet_style_prefer_collection_expression = true:suggestion
|
||||
csharp_style_prefer_primary_constructors = false:suggestion
|
||||
tab_width = 4
|
||||
indent_size = 4
|
||||
end_of_line = crlf
|
||||
|
@ -266,6 +265,7 @@ csharp_style_var_elsewhere = true:error
|
|||
csharp_style_var_when_type_is_apparent = true:error
|
||||
csharp_style_var_for_built_in_types = true:error
|
||||
csharp_space_around_binary_operators = before_and_after
|
||||
csharp_style_prefer_primary_constructors = false:suggestion
|
||||
|
||||
# Analyzer rules
|
||||
dotnet_analyzer_diagnostic.category-Style.severity = error
|
||||
|
|
|
@ -0,0 +1,41 @@
|
|||
name: Server - Build and Test
|
||||
|
||||
env:
|
||||
DOTNET_VERSION: '8.x'
|
||||
SOLUTION: Cobra.sln
|
||||
CONFIGURATION: Release
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "main" ]
|
||||
pull_request:
|
||||
branches: [ "main" ]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v3
|
||||
with:
|
||||
dotnet-version: ${{ env.DOTNET_VERSION }}
|
||||
|
||||
- name: Cache dependencies
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ~/.nuget/packages
|
||||
key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-nuget-
|
||||
|
||||
- name: Restore dependencies
|
||||
run: dotnet restore ${{ env.SOLUTION }}
|
||||
|
||||
- name: Build
|
||||
run: dotnet build --no-restore --configuration ${{ env.CONFIGURATION }} ${{ env.SOLUTION }}
|
||||
|
||||
- name: Test
|
||||
run: dotnet test --no-build --verbosity normal ${{ env.SOLUTION }}
|
|
@ -7,7 +7,8 @@
|
|||
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<IsPackable>false</IsPackable>
|
||||
<NoWarn>JSON002</NoWarn>
|
||||
<NoWarn>JSON002</NoWarn>
|
||||
<DisableImplicitNuGetFallbackFolder>true</DisableImplicitNuGetFallbackFolder>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
@ -611,7 +611,7 @@
|
|||
"runtime.native.System.Security.Cryptography.Apple": {
|
||||
"type": "Transitive",
|
||||
"resolved": "4.3.0",
|
||||
"contentHash": "jwjwlEL0Elv6gwoyaokRn12nv/JE+UW/DXJEbzhjCPvGbef36StnHKc9XaZD/rGWqYicrphZ7eumR/jdmNcjRg==",
|
||||
"contentHash": "DloMk88juo0OuOWr56QG7MNchmafTLYWvABy36izkrLI5VledI0rq28KGs1i9wbpeT9NPQrx/wTf8U2vazqQ3Q==",
|
||||
"dependencies": {
|
||||
"runtime.osx.10.10-x64.runtime.native.System.Security.Cryptography.Apple": "4.3.0"
|
||||
}
|
||||
|
@ -641,12 +641,12 @@
|
|||
"runtime.opensuse.42.1-x64.runtime.native.System.Security.Cryptography.OpenSsl": {
|
||||
"type": "Transitive",
|
||||
"resolved": "4.3.0",
|
||||
"contentHash": "G2+96gYRbzp1JZCID6B+u2XJ0bs2wCubd6rE3+Tj436dKfnciF7YgsLi2VvLeJq6kxYyU4IJrVrpCvC8Yf6bhA=="
|
||||
"contentHash": "KeLz4HClKf+nFS7p/6Fi/CqyLXh81FpiGzcmuS8DGi9lUqSnZ6Es23/gv2O+1XVGfrbNmviF7CckBpavkBoIFQ=="
|
||||
},
|
||||
"runtime.osx.10.10-x64.runtime.native.System.Security.Cryptography.Apple": {
|
||||
"type": "Transitive",
|
||||
"resolved": "4.3.0",
|
||||
"contentHash": "Kh9W4agE0r/hK8AX1LvyQI2NrKHBL8pO0gRoDTdDb0LL6Ta1Z2OtFx3lOaAE0ZpCUc/dt9Wzs3rA7a3IsKdOVA=="
|
||||
"contentHash": "kVXCuMTrTlxq4XOOMAysuNwsXWpYeboGddNGpIgNSZmv1b6r/s/DPk0fYMB7Q5Qo4bY68o48jt4T4y5BVecbCQ=="
|
||||
},
|
||||
"runtime.osx.10.10-x64.runtime.native.System.Security.Cryptography.OpenSsl": {
|
||||
"type": "Transitive",
|
||||
|
@ -656,12 +656,12 @@
|
|||
"runtime.rhel.7-x64.runtime.native.System.Security.Cryptography.OpenSsl": {
|
||||
"type": "Transitive",
|
||||
"resolved": "4.3.0",
|
||||
"contentHash": "T5NvFgmHX0WH4c7lP72krsnk+IJI10vJf2j2twGE+5QBRA4RyRAgD+ZjEgdmpLOjW4B+nZGaadewTCUcR899OQ=="
|
||||
"contentHash": "nyFNiCk/r+VOiIqreLix8yN+q3Wga9+SE8BCgkf+2BwEKiNx6DyvFjCgkfV743/grxv8jHJ8gUK4XEQw7yzRYg=="
|
||||
},
|
||||
"runtime.ubuntu.14.04-x64.runtime.native.System.Security.Cryptography.OpenSsl": {
|
||||
"type": "Transitive",
|
||||
"resolved": "4.3.0",
|
||||
"contentHash": "JGc0pAWRE8lB4Ucygk2pYSKbUPLlAIq6Bczf5/WF2D/VKJEPtYlVUMxk8fbl1zRfTWzSHi+VcFZlaPlWiNxeKg=="
|
||||
"contentHash": "ytoewC6wGorL7KoCAvRfsgoJPJbNq+64k2SqW6JcOAebWsFUvCCYgfzQMrnpvPiEl4OrblUlhF2ji+Q1+SVLrQ=="
|
||||
},
|
||||
"runtime.ubuntu.16.04-x64.runtime.native.System.Security.Cryptography.OpenSsl": {
|
||||
"type": "Transitive",
|
||||
|
|
Loading…
Reference in New Issue