Running Imported Tests with Require Prevents Click Into Test from Test Runner

I noticed that when I try to start managing my specs by running sets of files like this, I can no longer double click a test in the test runner to get to that test if it's been required in a top level describe.

describe('API', () => {
require('./api/user.api.spec.js')
require('./api/auth.api.spec.js')
})


When I do this, the tests run fine. But lets say I try to double-click a test in the test runner to get to a specific test, it no longer works, I get "Nothing Here" when I mouse over the green, red or yellow test that lives in any of those imported specs.


So is it just not something WebStorm supports?

0
1 comment

Yes, 'jumping to source is not supported when using such syntax; please feel free to file a request for supporting it to youtrack, https://youtrack.jetbrains.com/issues/WEB

0

Please sign in to leave a comment.