powsybl-core icon indicating copy to clipboard operation
powsybl-core copied to clipboard

Refactor assert command

Open Lisrte opened this issue 2 years ago • 1 comments

Please check if the PR fulfills these requirements

  • [x] The commit message follows our guidelines
  • [x] Tests for the changes have been added (for bug fixes / features)
  • [ ] Docs have been added / updated (for bug fixes / features)

Does this PR already have an issue describing the problem?

No

What kind of change does this PR introduce?

Refactor

What is the current behavior?

When using assertCommand in ToolTest, out and err stream are tested against expected out and err but values don't have to be strictly equals : expected values has to be found in the related stream. This function is useful for err stream when you want to match the type of error in a stack, but for output a strict comparison could be more useful.

What is the new behavior (if this is a feature change)? Separate strict and match comparison

Does this PR introduce a breaking change or deprecate an API?

  • [ ] The Breaking Change or Deprecated label has been added
  • [ ] The migration guide has been updated in the github wiki (What changes might users need to make in their application due to this PR?)

Other information:

Lisrte avatar Nov 14 '23 16:11 Lisrte