intellij icon indicating copy to clipboard operation
intellij copied to clipboard

Allow for more flexibility when reporting test failures

Open avshenuk opened this issue 5 years ago • 2 comments

Checklist

  • [x] I have filed an issue about this change and discussed potential changes with the maintainers.
  • [ ] I have received the approval from the maintainers to make this change.
  • [x] This is not a stylistic, refactoring, or cleanup change.

Please note that the maintainers will not be reviewing this change until all checkboxes are ticked. See the Contributions section in the README for more details.

Discussion thread for this change

Issue number: https://github.com/bazelbuild/intellij/issues/2149

Description of this change

When using certain assertion libraries, such as https://github.com/google/truth, the expected and actual value are not always present and the patterns defined in com.intellij.junit4.ExpectedPatterns are not covering all possible messages (actually I don't see them covering any of Google Truth messages).

But even without them, IMO the test should be considered a "failure" rather than an "error" when an assertion fails. This can be controlled by the means of the "error" XML element in the generated JUnit report making it much more flexible for the plugin users.

Additionally, a "system-err" element of the "testsuite" element is currently converted to a "system-out" output in the SM runner test console which seems to be a bug.

avshenuk avatar Oct 25 '20 14:10 avshenuk

Hello @avshenuk, Could you please fix the above buildkite checks. Thanks!

sgowroji avatar Sep 19 '22 06:09 sgowroji

@sgowroji And could you please tell how I can do it? :) It's been a long time, sorry...

avshenuk avatar Sep 19 '22 07:09 avshenuk

@sgowroji Done :)

avshenuk avatar Sep 28 '22 11:09 avshenuk