-
Notifications
You must be signed in to change notification settings - Fork 7
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
dynamic test name #1
Comments
Hello, |
what if string variables ${} would be converted to whildcard, test name would be converted to /is dynamic test name [.]+ [0-9]+/ and then on mouse over toMatchSnapshot we could display all matched snapshots? |
May be a good idea. I'll look |
Version 1.5.0 supports resolving constants in blocks, although probably this is not exactly that you've asked import { Api } from "./api";
const A = "A";
const B = 5;
it(Api.LOGIN, () => {
expect("Something").toMatchSnapshot();
});
it(`${Api.LOGIN} works with ${A} and ${B}`, () => {
expect("Something").toMatchSnapshot();
}); Hope this helps |
this does not work, its possible to write tests like this:
do you think it would be hard to add support for this case?
The text was updated successfully, but these errors were encountered: