|
|
|
@ -31,14 +31,13 @@ steps:
|
|
|
|
|
sonar_token:
|
|
|
|
|
from_secret: sonar_token
|
|
|
|
|
project_key: web_admin
|
|
|
|
|
coverage_exclusions: "Tests/**"
|
|
|
|
|
commands:
|
|
|
|
|
- dotnet restore WF-WebAdmin/WF-WebAdmin.sln
|
|
|
|
|
- dotnet restore WF-WebAdmin.sln
|
|
|
|
|
- dotnet sonarscanner begin /k:$${project_key} /d:sonar.host.url=$${sonar_host} /d:sonar.coverageReportPaths="coveragereport/SonarQube.xml" /d:sonar.coverage.exclusions=$${coverage_exclusions} /d:sonar.login=$${sonar_token}
|
|
|
|
|
- dotnet build WF-WebAdmin/WF-WebAdmin.sln -c Release --no-restore /p:AndroidSdkDirectory=$ANDROID_SDK_ROOT -property:Aapt2ToolPath=$ANDROID_SDK_ROOT/build-tools/33.0.0
|
|
|
|
|
- dotnet test WF-WebAdmin/WF-WebAdmin.sln --logger trx --no-restore /p:AndroidSdkDirectory=$ANDROID_SDK_ROOT -property:Aapt2ToolPath=$ANDROID_SDK_ROOT/build-tools/33.0.0 /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura --collect "XPlat Code Coverage"
|
|
|
|
|
- dotnet build WF-WebAdmin.sln -c Release --no-restore
|
|
|
|
|
- dotnet test WF-WebAdmin.sln --logger trx --no-restore /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura --collect "XPlat Code Coverage"
|
|
|
|
|
- reportgenerator -reports:"**/coverage.cobertura.xml" -reporttypes:SonarQube -targetdir:"coveragereport"
|
|
|
|
|
- dotnet publish WF-WebAdmin/WF-WebAdmin/WF-WebAdmin.csproj -c Release --no-restore -o $CI_PROJECT_DIR/build/release -f:net7.0-android /p:AndroidSdkDirectory=/usr/lib/android-sdk
|
|
|
|
|
- dotnet publish WF-WebAdmin.sln -c Release --no-restore -o $CI_PROJECT_DIR/build/release
|
|
|
|
|
- dotnet sonarscanner end /d:sonar.login=$${sonar_token}
|
|
|
|
|
|
|
|
|
|
- name: docker_build
|
|
|
|
|