No test result files matching test- xml were found - Azure DevOps

0 votes

I am trying to publish test results in azure but i am unable to do it. Its my second day with azure so i may be missing something.

My pipeline code is

- task: PublishTestResults@2
  inputs:
    testResultsFormat: 'JUnit'
    testResultsFiles: '**/test-*.xml'

karma.conf.js

junitReporter: {
             outputDir: '.',
             outputFile:'test-report.xml'
         },

And I am using the latest ubuntu. But always when I run pipeline I get this error

##[warning]No test result files matching **/test-*.xml were found.

I tried lowercase uppercase but nothing works and I don't know what I am doing wrong. I will be thankful for any hints.

Mar 29, 2022 in Azure by Edureka
• 12,690 points
4,849 views

1 answer to this question.

0 votes

Although the PublishTestResults task mentions JUnit, you must ensure that karma is producing JUnit reports. The excerpt from karma.conf.js you provided is insufficient to validate this.

 install karma-junit-reporter npm package

npm install karma-junit-reporter --save-dev

 add karma-junit-reporter in karma.conf.js plugins array

require('karma-junit-reporter')

add junit in karma.conf.js reporters array

reporters: ['progress', 'kjhtml', 'junit'],

Then make sure the PublishTestResults task has the correct pattern. Mine looks like this because I don't specify any junitReporter settings, which you show in your example.

testResultsFiles: "**/TESTS*.xml"

If you are interested in learning DevOps from scratch then checkout Edureka's DevOps Training Course.

answered Mar 30, 2022 by Edureka
• 13,620 points

Related Questions In Azure

0 votes
1 answer

Test environment for microsoft graph api and Azure v2.0

Yes, the type of application you register ...READ MORE

answered Mar 2, 2022 in Azure by Edureka
• 12,690 points
767 views
0 votes
1 answer

Unzip gzip files in Azure Data factory

How to unzip a GZIP file? here's ...READ MORE

answered Mar 24, 2022 in Azure by Edureka
• 12,690 points
2,256 views
0 votes
1 answer

Azure AzCopy command fail to copy csv files to Azure Storage

try using the below command: azcopy copy [source] ...READ MORE

answered Mar 24, 2022 in Azure by Edureka
• 12,690 points
3,391 views
0 votes
1 answer

Add image to Azure Devops Dashboard

Markdown is a web writer's text-to-HTML conversion ...READ MORE

answered Mar 26, 2022 in Azure by Edureka
• 12,690 points
861 views
0 votes
2 answers

What is the role of TestNG & JUnit frameworks in Selenium?

TestNG and JUnit are test frameworks . it ...READ MORE

answered Sep 4, 2020 in Selenium by Sri
• 3,190 points
2,932 views
0 votes
2 answers

Finding WebDriver element with Class Name in java

The better way to handle this element ...READ MORE

answered Apr 10, 2018 in Selenium by nsv999
• 5,500 points
13,762 views
0 votes
2 answers

Problem while using InternetExplorerDriver in Selenium WebDriver

enable trusted connection  in internet explorer by ...READ MORE

answered Aug 31, 2020 in Selenium by Sri
• 3,190 points
9,184 views
0 votes
1 answer

Geo-location microphone camera pop up

To Allow or Block the notification, access using Selenium and you have to ...READ MORE

answered May 11, 2018 in Selenium by Samarpit
• 5,910 points
7,258 views
0 votes
1 answer

What is the Difference between VSO, VSTS and Azure Devops

Azure DevOps was previously known as VSO ...READ MORE

answered Mar 8, 2022 in Azure by Edureka
• 13,620 points

edited Jun 27, 2023 by Khan Sarfaraz 1,828 views
0 votes
1 answer

Azure DevOps - Github status checks

To use the GitHub Status check, first ...READ MORE

answered Mar 25, 2022 in Azure by Edureka
• 13,620 points
1,090 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP