question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

PublishCodeCoverageResults could not find file

See original GitHub issue

Hi,

I am running karma tests and getting cobertura.xml. I keep getting file not found error:

2016-12-24T18:21:41.5365253Z ##[error]System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\a\_tasks\PublishCodeCoverageResults_2a7ebc54-c13e-490e-81a5-d7561ab7cd97\1.0.17\coverage'.
20

Starting 'Publish-CodeCoverage' cmdlet
2016-12-24T18:21:41.9972815Z ##[error]System.ArgumentException: File 'coverage/cobertura.xml' does not exist or is not accessible.

my publish testresults task is working correctly, it is in the same directory. Is my configuration wrong? Do I need to add another task before doing so?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
yss14commented, Aug 1, 2018

@tanvi-soni I just ran into the same problem. File 'cobertura-coverage.xml' does not exist or is not accessible.. When inspecting the assets of the build, the file is located in the root dir of my project. As summary file path I specified cobertura-coverage.xml, report directory and additional files field is blank.

screen shot 2018-08-01 at 16 38 47

1reaction
rldcampbellcommented, Aug 21, 2018

I’m also getting this same issue - I can publish the code coverage file as an artifact so it is there, but I’m getting the two errors: ##[error]Unable to process command '##vso[codecoverage.publish codecoveragetool=Cobertura;summaryfile=UploadTool/coverage/cobertura-coverage.xml;]' successfully. Please reference documentation (http://go.microsoft.com/fwlink/?LinkId=817296) ##[error]File 'UploadTool/coverage/cobertura-coverage.xml' does not exist or is not accessible. Is there a reason it would not be accessible?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Publish Code Coverage Results task is not publishing report ...
Version 1.150.2 of the Publish Code Coverage Results task is not publishing the report files found in the reportDirectory. Previous build for commit...
Read more >
Publish code coverage not finding coverage file in Azure ...
I've found a way accidentally. It looks like Jest can generate cobertula coverage report. It needs to be added in Jest configuration.
Read more >
Publish code coverage results v1 task - Microsoft Learn
Publish code coverage results v1 # Publish Cobertura or JaCoCo ... Fails the task if code coverage did not produce any results to...
Read more >
how to view Code Coverage report on Azure DevOps - Code4IT
xml, that is the file we will use in the next step to publish the coverage results. dotnet test generated files. Publish code...
Read more >
Combining multiple code coverage results in Azure DevOps
Here we'll explore how to easily get this set up in your existing Azure DevOps ... You can then view these results based...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found