Giter Club home page Giter Club logo

cikit's Introduction

CI Kit

Playground project using Rust to build a minimum viable CI reporting tool.

Goals

  • Provide a minimal but functional UI to display JUnit test reports both through the CLI and as an HTML document.
  • Notify test outcome through various channels: i.e. slack web-hooks, github comments/annotations, email, etc.
  • Have fun!

Features

A rudimentary React-based HTML viewer is already implemented:

cikit HTML report rendering

Note: in order to view the generated reports, you will need to run a webserver using the report folder as the document root (e.g cd report && python2 -m SimpleHTTPServer 8000).

Also, reports can be rendered in the console using the even more crude text format:

cikit text report rendering

Usage

cikit 0.1.0
The continuous integration reporting toolkit

USAGE:
    cikit --config-path <config-path> [project-dir] <SUBCOMMAND>

FLAGS:
    -h, --help       Prints help information
    -V, --version    Prints version information

OPTIONS:
    -c, --config-path <config-path>    Input file

ARGS:
    <project-dir>

SUBCOMMANDS:
    help           Prints this message or the help of the given subcommand(s)
    notify         Notifies the build outcome via Slack
    test-report    Reads the Junit test report

Building and running

In order to statically embed a small set of web assets into its executable, cikit wraps its UI build (React/TypeScript) into a Cargo build. Assuming you have both npm and rustup (default toolchain) installed, you should be able to build the project in one go by simply running:

cargo build

and then

cargo test to execute the test suite.

Finally, you can iteratively recompile and run the program by prefixing the normal executable call with cargo run --:

RUST_LOG='cikit=debug' RUST_BACKTRACE=1 cargo run -- \ 
   -c sample.config.toml ~/code/project-with-junit \ 
   test-report html -o test-report -f

You might want to amend the report_dir_pattern config value with a glob expression that matches your project junit XML report dir/s.

Development status

๐Ÿ˜ด This project is currently in a dormant state and is not being actively maintained.

cikit's People

Contributors

afiore avatar dependabot[bot] avatar

Watchers

 avatar  avatar

cikit's Issues

Allow parsing nested list of testsuites

We currently expect one testsuite per file, as produced by scalatest. Other tools might behave differently and deserialise the whole project testsuites into a single file

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.