Skip to content

Standard test output is not logged to allure for failed tests, but logged for success test #31

Open
sphinxy opened this issue Feb 1, 2023 · 0 comments · May be fixed by #32
Open

Standard test output is not logged to allure for failed tests, but logged for success test #31

sphinxy opened this issue Feb 1, 2023 · 0 comments · May be fixed by #32

Comments

@sphinxy
Copy link
Contributor

sphinxy commented Feb 1, 2023

If we use xunit's TestOutputHelper to log something, it also appear in allure, but only for success tests. For failed tests exceptions are logged but test output is missing in allure.

So if we have some debug output like "Sample test userId = 123", test start failing and we compare test results, we don't see useful debug info in comparison.

e.g. for imaginary test GetUserNameByUserId() with some logging inside:

Success test sample output :

"Sample test userId = 123"
"Received username is Oleg"

Current failed test output:
"Assert.Equal() Failure (pos 0) Expected: "Oleg" Actual: "MissingName"

Fixed new failed test output:

"Assert.Equal() Failure        (pos 0) Expected: "Oleg" Actual:   "MissingName"
"Sample test userId = 123"
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant