Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a good way to use this with projects? #106

Closed
bencooper222 opened this issue Oct 11, 2019 · 3 comments
Closed

Is there a good way to use this with projects? #106

bencooper222 opened this issue Oct 11, 2019 · 3 comments

Comments

@bencooper222
Copy link

This reporter works with the jest projects array but all that happens is the last project to run overwrites the file. I'd either like it to append to the original file or create separate files. Is there a way to do this?

@palmerj3
Copy link
Collaborator

Can you provide a sample repo that shows this happening?

jest-junit has been used in multi-project environments and I haven't heard of the junit.xml file being overwritten.

@andrcuns
Copy link
Contributor

@bencooper222 as per discussion in #108, if You have multiple projects, You simply need to prefix test run command with appropriate env variable, JEST_JUNIT_OUTPUT_NAME=project_1.xml npm test..., JEST_JUNIT_OUTPUT_NAME=project_2.xml npm test... so each run generates it's own xml file.

@bencooper222
Copy link
Author

ahhhh thanks so much @andrcuns

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants