GithubHelp home page GithubHelp logo

honsa / xunit-slack-reporter Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ivanklee86/xunit-slack-reporter

0.0 1.0 0.0 257 KB

Github Action to send XUnit results to Slack ๐ŸŽ™๏ธ๐ŸŽ™๏ธ๐ŸŽ™๏ธ

License: MIT License

Dockerfile 11.49% Makefile 10.75% Python 66.31% Shell 0.41% HCL 11.04%

xunit-slack-reporter's Introduction

xUnit Slack Reporter

Github Action to send xUnit results to Slack.

What it does!

This action will:

  • Parse a xUnit-style XML report.
  • Send summary to Slack workspace & channel of your choice.
  • (Optional) Fail the build if errors or failures are found.

What you need!

Setting up the action

The following environment variables are supported:

Environment Variable Description Required?
XUNIT_PATH Path (relative to workspce directory) to xUnit report Y
SLACK_TOKEN Slack bot user token Y
SLACK_CHANNEL Unique ID of slack channel to notify Y
EXIT_CODE_FROM_REPORT If present, will fail workflow if errors or failures are in the report N

Sample Workflow section:

action "testsnotify" {
  needs = "tests"
  uses = "ivanklee86/xunit-slack-reporter@master"
  env = {
    SLACK_CHANNEL = "AAAAAAAA"
    XUNIT_PATH = "./results.xml"
    EXIT_CODE_FROM_REPORT = "True"
  },
  secrets = ["SLACK_TOKEN"]
}

    - name: notify-tests
      uses: ./
      env:
        EXIT_CODE_FROM_REPORT: "True"
        SLACK_CHANNEL: CKQ7C7KJN
        SLACK_TOKEN: ${{ secrets.SLACK_TOKEN }}
        XUNIT_PATH: ./results.xml

xunit-slack-reporter's People

Contributors

dependabot-preview[bot] avatar ivanklee86 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.