@@ -56,7 +56,7 @@ echo "Build entire solution"
5656exec { & dotnet build - c Release }
5757
5858echo " Tests Core version"
59- dotnet test - c Release -- test-adapter - path:. -- logger:" nunit;LogFilePath=TestResults\core-results.xml"
59+ dotnet test - c Release -- test-adapter - path:. -- logger:" nunit;LogFilePath=$ ( $ env: APPVEYOR_BUILD_FOLDER ) \ TestResults\core-results.xml"
6060
6161$corePassed = $lastexitcode
6262
@@ -65,14 +65,14 @@ Remove-Item -Path ".\src\HodStudio.EntityFrameworkDiffLog.TestsDotNet45\bin\Rele
6565Rename-Item - Path " .\src\HodStudio.EntityFrameworkDiffLog.TestsDotNet45\bin\Release\App.Release.config" - NewName " HodStudio.EntityFrameworkDiffLog.TestsDotNet45.dll.config"
6666
6767echo " Tests 4.5 version"
68- .\packages\NUnit.ConsoleRunner.3.10 .0 \tools\nunit3-console.exe .\src\HodStudio.EntityFrameworkDiffLog.TestsDotNet45\bin\Release\HodStudio.EntityFrameworkDiffLog.TestsDotNet45.dll -- result= . \TestResults\net45- results.xml
68+ .\packages\NUnit.ConsoleRunner.3.10 .0 \tools\nunit3-console.exe .\src\HodStudio.EntityFrameworkDiffLog.TestsDotNet45\bin\Release\HodStudio.EntityFrameworkDiffLog.TestsDotNet45.dll -- result= " $ ( $ env: APPVEYOR_BUILD_FOLDER ) \TestResults\net45-results.xml"
6969
7070$net45Passed = $lastexitcode
7171
7272echo " Upload results to AppVeyor"
7373$wc = New-Object ' System.Net.WebClient'
74- $wc.UploadFile (" https://ci.appveyor.com/api/testresults/nunit3/$ ( $env: APPVEYOR_JOB_ID ) " , (Resolve-Path " . \TestResults\net45-results.xml" ))
75- $wc.UploadFile (" https://ci.appveyor.com/api/testresults/nunit3/$ ( $env: APPVEYOR_JOB_ID ) " , (Resolve-Path " .\src\HodStudio.EntityFrameworkDiffLog.TestsDotNetCore \TestResults\core-results.xml" ))
74+ $wc.UploadFile (" https://ci.appveyor.com/api/testresults/nunit3/$ ( $env: APPVEYOR_JOB_ID ) " , (Resolve-Path " $ ( $ env: APPVEYOR_BUILD_FOLDER ) \TestResults\net45-results.xml" ))
75+ $wc.UploadFile (" https://ci.appveyor.com/api/testresults/nunit3/$ ( $env: APPVEYOR_JOB_ID ) " , (Resolve-Path " $ ( $ env: APPVEYOR_BUILD_FOLDER ) \TestResults\core-results.xml" ))
7676
7777$errorMessage = $NULL
7878
@@ -134,19 +134,17 @@ echo "Starting Sonar for Library"
134134
135135if ($env: APPVEYOR_PULL_REQUEST_NUMBER -ne $null )
136136{
137- exec { & dotnet sonarscanner begin / d:sonar.login= " $env: sonartoken " / key:" HodStudio.EntityFrameworkDiffLog" / o:" hodstudio-github" / d:sonar.sources= " .\src\HodStudio.EntityFrameworkDiffLog" / d:sonar.host.url= " https://sonarcloud.io" / d:sonar.pullrequest.base= " $env: APPVEYOR_REPO_BRANCH " / d:sonar.pullrequest.branch= " $env: APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH " / d:sonar.pullrequest.key= " $env: APPVEYOR_PULL_REQUEST_NUMBER " / d:sonar.pullrequest.provider= " GitHub" / d:sonar.pullrequest.github.repository= " $env: APPVEYOR_REPO_NAME " / d:sonar.coverageReportPaths= " . \testresults\SonarQube.xml" }
137+ exec { & dotnet sonarscanner begin / d:sonar.login= " $env: sonartoken " / key:" HodStudio.EntityFrameworkDiffLog" / o:" hodstudio-github" / d:sonar.sources= " .\src\HodStudio.EntityFrameworkDiffLog" / d:sonar.host.url= " https://sonarcloud.io" / d:sonar.pullrequest.base= " $env: APPVEYOR_REPO_BRANCH " / d:sonar.pullrequest.branch= " $env: APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH " / d:sonar.pullrequest.key= " $env: APPVEYOR_PULL_REQUEST_NUMBER " / d:sonar.pullrequest.provider= " GitHub" / d:sonar.pullrequest.github.repository= " $env: APPVEYOR_REPO_NAME " / d:sonar.coverageReportPaths= " $ ( $ env: APPVEYOR_BUILD_FOLDER ) \testresults\SonarQube.xml" }
138138}
139139else
140140{
141- exec { & dotnet sonarscanner begin / d:sonar.login= " $env: sonartoken " / key:" HodStudio.EntityFrameworkDiffLog" / o:" hodstudio-github" / d:sonar.sources= " .\src\HodStudio.EntityFrameworkDiffLog" / d:sonar.host.url= " https://sonarcloud.io" / version:" $completeVersion " / d:sonar.coverageReportPaths= " . \testresults\SonarQube.xml" }
141+ exec { & dotnet sonarscanner begin / d:sonar.login= " $env: sonartoken " / key:" HodStudio.EntityFrameworkDiffLog" / o:" hodstudio-github" / d:sonar.sources= " .\src\HodStudio.EntityFrameworkDiffLog" / d:sonar.host.url= " https://sonarcloud.io" / version:" $completeVersion " / d:sonar.coverageReportPaths= " $ ( $ env: APPVEYOR_BUILD_FOLDER ) \testresults\SonarQube.xml" }
142142}
143143
144144exec { & dotnet build $libraryOnlySolutionPath - c Release }
145145
146146dotnet test - c Release - s " $ ( $env: APPVEYOR_BUILD_FOLDER ) \coverletArgs.runsettings" - r " $ ( $env: APPVEYOR_BUILD_FOLDER ) \TestResults\"
147147
148- Get-ChildItem - Path " TestResults" | Resolve-Path - Relative
149-
150148exec { & reportgenerator " -reports:$ ( $env: APPVEYOR_BUILD_FOLDER ) \TestResults\*\*.xml" " -targetdir:$ ( $env: APPVEYOR_BUILD_FOLDER ) \TestResults\" " -reporttypes:SonarQube" }
151149
152150exec { & dotnet sonarscanner end / d:sonar.login= " $env: sonartoken " }
0 commit comments