Giter Site home page Giter Site logo

test-results's People

Contributors

hamir-suspect avatar lucaspin avatar ralopes avatar shiroyasha avatar skipi avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

aleksandarcole

test-results's Issues

Combining multiple files fails to upload raw xml

When test results CLI is being used to publish multiple files:

test-results publish file1.xml file2.xml file3.xml

Generated junit.json file is being correctly sent to artifact storage, however due to the fact, that xml files are not really merged, CLI tries to upload 3 files, and fails on 2nd one (due to file being present in artifact storage).

I will think about some solution that we can implement and update the issue.

Add a parser for PHPUnit JUnit files

Publishing PHPUnit JUnit files results in empty JSON files, no matter which parser you use.
This is probably because PHPUnit creates files with nested testsuite tags, like this:

<?xml version="1.0" encoding="UTF-8"?>
<testsuites>
  <testsuite name="test" tests="3" assertions="13" errors="0" failures="0" skipped="0" time="0.001504">
    <testsuite name="" file="" tests="2" assertions="11" errors="0" failures="0" skipped="0" time="0.001226">
      <testcase name="" class=" file="" line="16" assertions="4" time="0.001150"/>
      <testcase name="" class="" classname="" file="" line="39" assertions="7" time="0.000076"/>
    </testsuite>
    <testsuite name="" file="" tests="1" assertions="2" errors="0" failures="0" skipped="0" time="0.000278">
      <testcase name="" class="" classname="" file="" line="15" assertions="2" time="0.000278"/>
    </testsuite>
  </testsuite>
</testsuites>

(class and filesnames are redacted)

Parse durations that use scientific notation

Some JUnit exporters report timestamps in scientific notation, which results in the following warning:

* Duration parsing failed: time: unknown unit "e-" in duration "8.10623168945312e-05s"

Test

Testing Slack integration.

`test-results publish` returns exitcode zero if file is not found

This is a problem since the CI-pipeline (where most people will use this), will show that the task finished correctly, which is not true.
Returning a non-zero exit code will fix this, and also conforms more to the meaning of exit codes.

To reproduce the issue:

$ test-results publish path/to/nonexisting/file.xml
* Input file read failed: stat .junit/unittests.xml: no such file or directory
$ echo $?
0

Update integrations tests for workflow

I had to remove the workflow integration test for now, we need to figure it out how to handle the case where the parser does not implement IsApplicable() and generic can't handle properly the input.

IsApplicable() is not implemented for embedded and phpunit, which breaks the workflow integration test.

CC @skipi

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.