jest-junit icon indicating copy to clipboard operation
jest-junit copied to clipboard

Added optional owner-attribute for testcase

Open work933k opened this issue 1 year ago • 3 comments

This PR proposes to add support for defining the owner-attribute of testcase. This attribute is used by Azure Devops' PublishTestResult-task

This should be a non-breaking change as the ownerName is optional.

work933k avatar Sep 05 '24 11:09 work933k

Thanks for submitting a PR!

I need to do some work on the CI here before I'll be able to merge.

For this feature, I would like you to consider enabling different owners for different tests. Your approach assumes a single owner for an entire suite.

Have a look what we did to support custom test suite properties and an approach similar to that might be justified.

https://github.com/jest-community/jest-junit/blob/master/utils/buildJsonResults.js#L158

palmerj3 avatar Sep 05 '24 11:09 palmerj3

Thank you for your quick response.

I understand your suggestion to support different owners for different tests. But maybe it would be a good to initially start small/easy with this implementation?

work933k avatar Sep 05 '24 12:09 work933k

Since you're adding a config / cli arg to specify the owner, if we move to multi-owner later on then that config goes away. Could be avoided altogether.

palmerj3 avatar Sep 05 '24 12:09 palmerj3