Skip to content

[tests] switch to using insta for handling expected results#2

Merged
ttiimm merged 1 commit into
ttiimm:mainfrom
tstack:instatests
Sep 4, 2025
Merged

[tests] switch to using insta for handling expected results#2
ttiimm merged 1 commit into
ttiimm:mainfrom
tstack:instatests

Conversation

@tstack

@tstack tstack commented Sep 2, 2025

Copy link
Copy Markdown
Contributor

The insta library seems like a reasonable way to do snapshot testing. Changing this first so I can make sense of test failures as I do other things.

Comment thread tests/utils.rs
let normalized = if path_sep == '/' {
path_str.to_string()
} else {
// On Windows, swap the forward slash for backslashes

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any thoughts on how to make the tests cross platform?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a "Redactions" feature that might help -- https://insta.rs/docs/redactions/

@ttiimm ttiimm merged commit dccb84f into ttiimm:main Sep 4, 2025
2 of 6 checks passed
@tstack

tstack commented Sep 4, 2025

Copy link
Copy Markdown
Contributor Author

I'm not sure why the actions failed. Do they need some tweaking to work with PRs?

@ttiimm

ttiimm commented Sep 4, 2025

Copy link
Copy Markdown
Owner

I'm not sure why the actions failed. Do they need some tweaking to work with PRs?

Yeah, think I have this fixed.

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

Successfully merging this pull request may close these issues.

2 participants