DEV Community

Cover image for Report test results to slack or microsoft teams
Anudeep
Anudeep

Posted on • Edited on

Report test results to slack or microsoft teams

Sharing the test results to the right places at the right time is very important when you are working in a high velocity organisations.

And also having the right platform where teams can discuss transparently on the test failures is also equally important.

These test results come in different forms like JUnit, TestNG, xUnit and many more from testing tools like Selenium, Cypress or RestAssured. Similarly organisations use different communication platforms like Slack, Microsoft Teams., etc for sending different kinds of alerts.

TestBeats

TestBeats is a command line tool that solves this problem elegantly. It allows us to publish test results to different entities. Even it allows us to customise the report to include hyperlinks, reportportal analysis, mentioning users based on a on-call schedule and more.

GitHub logo test-results-reporter / testbeats

Publishes test results to Microsoft Teams, Google Chat & Slack

This npm package has been renamed from test-results-reporter to testbeats. test-results-reporter will soon be phased out, and users are encouraged to transition to testbeats.

logo

Publish test results to Microsoft Teams, Google Chat, Slack and many more.


Build Downloads Size

Stars Downloads



TestBeats is a tool designed to streamline the process of publishing test results from various automation testing frameworks to communication platforms like slack, teams and more for easy access and collaboration. It unifies your test reporting to build quality insights and make faster decisions.

It supports all major automation testing frameworks and tools.

Read more about the project at https://testbeats.com

Sample Reports

Alerts in Slack

testbeats-failure-summary

Results in Portal

testbeats-failure-summary


Need Help

We use Github Discussions to receive feedback, discuss ideas & answer questions. Head over to it and feel free to start a discussion. We are always happy to help 😊.

Support Us

Like this project! Star it on Github ⭐. Your support…

Sample Reports

Slack

slack

Teams

teams

Top comments (6)

Collapse
 
maxkom profile image
Max Komarenko

Hi Anudeep, Is there a way to send only a summary for mocha json reporter e.g. only fail/pass stats instead of the list of all tests?

Collapse
 
asaianudeep profile image
Anudeep

We can use publish option as test-summary-slim to only see limited details.

{
  "name": "slack",
  "inputs": {
    "url": "<slack-incoming-webhook-url>",
    "publish": "test-summary-slim"
  }
}
Enter fullscreen mode Exit fullscreen mode
Collapse
 
sabbirof profile image
sabbir-of

Hi Anudeep , i am working with playwright. so how can i use this package for playwright..
I have used all the steps you have shown in this package config section. But I can't use it. so please share a solution for me. i am using azure devops and i want intagrated with ms team. Thanks

Image description

Collapse
 
asaianudeep profile image
Anudeep

@sabbirof There was an additional root level config property to be added in the earlier versions of the package. With the latest release, we don't need to it. If you still face an issue., please share the config file with us.

Collapse
 
chowdaryios profile image
chowdaryIOS

Hi Anudeep , i am also working on the same thing like sending mochawesome html reports to teams. please share some knowledge , if you have any idea in this.

Collapse
 
asaianudeep profile image
Anudeep

I think there is a way to upload HTML files via Microsoft Teams bots/apps. The test-results-reporter cli uses incoming webhook urls which can only send text messages.

A clean and easy solution would be to save your mochawesome html report as an artifact in your CI/CD pipeline. Then use the artifact url in your teams message using hyperlinks extension - test-results-reporter.github.io/ex...