Skip to content

Add option to show reference output in check results #116

@agoscinski

Description

@agoscinski

Right now assert allclose output is like this

assert_numpy_allclose failed for
|   x: array([0.        , 3.14159265, 6.28318531])
| > output 0: [ 1. -1.  1.]
| Output is not close to reference absolute difference is 3.0, relative difference is 3.0.

For assert_equal it works because it is in the message

assert_equal failed for
|   x: 2
| > output 0: 2
| Expected 4 but got 2.

But it would be nice if the reference output can be shown like this

assert_numpy_allclose failed for
|   x: array([0.        , 3.14159265, 6.28318531])
| > output 0: [ 1. -1.  1.]
| > ref output 0: [0., 0., 0.]
| Output is not close to reference absolute difference is 3.0, relative difference is 3.0.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions