Repository navigation
Improve WebStorm test-runner support - #180
Conversation
…an produce gutter run icons. Additionally, add WebStorm run configurations for oxlint and unit tests.
|
this seems unfortunate 👀 the rule tester itself creates the right context, so this seems like a bit of a hack to get an editor to be happy with that... this seems better solved in a webstorm plugin of some sort, to make it aware of |
Agreed 😅 Unfortunately it doesn't seem like JetBrains is in any hurry to get that sorted though. There's been an open feature request for this for several years with no activity https://youtrack.jetbrains.com/issue/WEB-40108
🤔 I'll have a look at writing a plugin, from a quick glance it seems like it is probably somewhat feasible. Sounds like you'd rather direct WebStorm users towards something like that rather than this? (totally fine if so, just want to check I'm understanding correctly 😄) Would you be open to accepting a reduced PR with just the project run configurations instead, with all of the |
|
I've removed everything other than the run configs, now that a plugin is viable instead 🫡 |

Currently, if you open this repo in WebStorm, it can't statically analyse the rule test files or mark them as runnable, so context-menu actions and gutter icons don't appear for those tests.
This makes testing in WebStorm more difficult than it needs to be.
This PR adds
describewrappers to each of those test cases, which give WebStorm enough context to detect that tests are present and to let the user run them (for the whole suite, though not individual cases) accordingly.This means that WebStorm now shows users context-menu actions and test gutter icons, and generally handles the tests better.
This PR also adds two default Run Configurations for IntelliJ/Webstorm users that provide an out-of-the-box configuration to: