Update '.drone.yml'
continuous-integration/drone/push Build is failing Details

pull/26/head
Matheo HERSAN 2 years ago
parent 33f124a9e1
commit 1112359ed6

@ -5,14 +5,13 @@ name: MangaMap
trigger: trigger:
branch: branch:
- master - master
- C#/model
event: event:
- push - push
steps: steps:
- name: build - name: build
image: hub.codefirst.iut.uca.fr/marc.chevaldonne/codefirst-dotnet7-maui:latest image: mcr.microsoft.com/dotnet/sdk:7.0
volumes: volumes:
- name: Documentation - name: Documentation
path: /Documentation path: /Documentation
@ -20,12 +19,14 @@ steps:
- cd MangaMap/ - cd MangaMap/
- dotnet restore MangaMap.sln - dotnet restore MangaMap.sln
- dotnet build MangaMap.sln -c Release --no-restore - dotnet build MangaMap.sln -c Release --no-restore
- dotnet publish SolutionTest.sln -c Release --no-restore -o $CI_PROJECT_DIR/build/release
- name: tests - name: tests
image: hub.codefirst.iut.uca.fr/marc.chevaldonne/codefirst-dotnet7-maui:latest image: mcr.microsoft.com/dotnet/sdk:7.0
commands: commands:
- cd MangaMap/ - cd MangaMap/
- dotnet restore MangaMap.sln - dotnet restore MangaMap.sln
- dotnet test MangaMap.sln --logger trx --no-restore /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura --collect "XPlat Code Coverage" - dotnet test MangaMap.sln --logger trx --no-restore
depends_on: [build] depends_on: [build]
- name: code-analysis - name: code-analysis
@ -33,7 +34,7 @@ steps:
commands: commands:
- cd MangaMap/ - cd MangaMap/
- dotnet restore MangaMap.sln - dotnet restore MangaMap.sln
- dotnet sonarscanner begin /k:TestCI /d:sonar.host.url=$${PLUGIN_SONAR_HOST} /d:sonar.coverageReportPaths="coveragereport/SonarQube.xml" /d:sonar.coverage.exclusions="Tests/**" /d:sonar.login=$${PLUGIN_SONAR_TOKEN} - 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}
- reportgenerator -reports:"**/coverage.cobertura.xml" -reporttypes:SonarQube -targetdir:"coveragereport" - reportgenerator -reports:"**/coverage.cobertura.xml" -reporttypes:SonarQube -targetdir:"coveragereport"
- dotnet publish MangaMap.sln -c Release --no-restore -o CI_PROJECT_DIR/build/release - dotnet publish MangaMap.sln -c Release --no-restore -o CI_PROJECT_DIR/build/release
- dotnet sonarscanner end /d:sonar.login=$${PLUGIN_SONAR_TOKEN} - dotnet sonarscanner end /d:sonar.login=$${PLUGIN_SONAR_TOKEN}

Loading…
Cancel
Save