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

Extra underscore in snapshot filename with 9.5.1 compared to 9.4.0 #264

Open
ynnckcmprnl opened this issue Mar 24, 2023 · 1 comment
Open

Comments

@ynnckcmprnl
Copy link

ynnckcmprnl commented Mar 24, 2023

Context: updating Quick/Nimble/Nimble-Snapshots to the latest version coming from Quick 10.x

After adding @mainactor to our snapshot tests, all our snapshots tests were failing. When I rerecord the snapshots there's an extra underscore in the filename at the end, the actual snapshot is the same as before, the filename is not.

Screenshot 2023-03-24 at 09 28 14

It seems that the name property on XCTActivity returns an extra colon which when processed causes the extra underscore. Still not quite sure why, since it's code from Apple that hasn't changed.

Behaviour with Quick 5.0.1, Nimble 10.0.0, Nimble-Snapshots 9.4.0:
Screenshot 2023-03-24 at 12 53 12

Behaviour with Quick 6.1.0, Nimble 11.2.1, Nimble-Snapshots 9.5.1:
Screenshot 2023-03-24 at 12 53 57

Since this hasn't been posted before, am I missing something obvious or could this be side-effect from switching to the new async approach in Quick?

@ashfurrow
Copy link
Owner

Sorry for the (very) delayed response. I think you're right that this is a side-effect of something, since the filenames are derived from the unit test names, which are themselves derived by Quick.

In these cases, I found it helpful to regenerate the screenshots entirely.

I hope that answers the question?

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

No branches or pull requests

2 participants