diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 6e887ad..5e2e4c3 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -75,7 +75,7 @@ jobs: - name: Generate artifact attestation uses: actions/attest-build-provenance@main with: - subject-path: src/PDFtoImage/bin/${{ github.event_name != 'workflow_dispatch' && 'Debug' || inputs.build_configuration }}/*.nupkg + subject-path: PDFtoZPL/bin/${{ github.event_name != 'workflow_dispatch' && 'Debug' || inputs.build_configuration }}/*.nupkg - name: Publish libraries uses: actions/upload-artifact@main with: @@ -238,7 +238,7 @@ jobs: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} shell: powershell run: | - .\.sonar\scanner\dotnet-sonarscanner begin /k:"sungaila_PDFtoImage" /o:"sungaila" /d:sonar.token="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.cs.vscoveragexml.reportsPaths=coverage.xml + .\.sonar\scanner\dotnet-sonarscanner begin /k:"sungaila_PDFtoZPL" /o:"sungaila" /d:sonar.token="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="https://sonarcloud.io" /d:sonar.cs.vscoveragexml.reportsPaths=coverage.xml dotnet build PDFtoZPL.SonarCloud.slnf -c ${{ github.event_name != 'workflow_dispatch' && 'Debug' || inputs.build_configuration }} dotnet-coverage collect "dotnet test PDFtoZPL.SonarCloud.slnf --verbosity detailed" -f xml -o "coverage.xml" .\.sonar\scanner\dotnet-sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN }}" \ No newline at end of file diff --git a/Tests/ApiTests.cs b/Tests/ApiTests.cs index af596cf..846a5ce 100644 --- a/Tests/ApiTests.cs +++ b/Tests/ApiTests.cs @@ -37,11 +37,13 @@ public void PdfByteArrayNullException() Assert.ThrowsException(() => ConvertPdfPage((byte[])null!)); } +#if NET6_0_OR_GREATER [TestMethod] public void PageNumberException() { - Assert.ThrowsException(() => ConvertPdfPage(string.Empty, page: -1)); + Assert.ThrowsException(() => ConvertPdfPage(string.Empty, -1)); } +#endif [TestMethod] public void PdfAllStreamNullException()