Open sw-tracker opened 4 months ago
Hey @sw-tracker can you share a reproduction repo? I just tried and I got the correct behavior for include:
And exclude:
I will setup a repo to reproduce it. In the meantime I can give you the dependency versions I have in my project:
"@storybook/addon-actions": "7.0.2",
"@storybook/addon-coverage": "0.0.8",
"@storybook/addon-docs": "7.0.2",
"@storybook/addon-essentials": "7.0.2",
"@storybook/addon-interactions": "7.0.2",
"@storybook/addon-links": "7.0.2",
"@storybook/jest": "0.1.0",
"@storybook/react": "7.0.2",
"@storybook/react-webpack5": "7.0.2",
"@storybook/test-runner": "0.18.1",
"@storybook/testing-library": "0.1.0",
"storybook": "7.0.2",
"storybook-addon-manual-mocks": "0.1.1",
"storybook-addon-mock": "4.0.0",
Maybe it has something to do with the versions I have.
I found how to reproduce it, as soon as you have playwright tests in the stories file, the tags start to misbehave.
BlahButton2PrimaryStory2.play = async ({ args }) => {
};
You can see the bug here: https://github.com/sw-tracker/storybook-reproduce-tag-problem
The command above should only run 1 of the tests, not both.
Describe the bug
I have created 1 tag which I have added to some tests.
I then run these 2 commands:
I expect the command that has
includeTags
to run my 24 tests and the command that hasexcludeTags
to run all of the other tests that dont have the tagsequential-test-execution
. But instead I get this:I have 24 story files in total. As you can see, the first command is skipping all tests (even those that have the tag), and the second command is executing all tests. How am I meant to use this tag to filter tests using the test-runner?
To Reproduce
System