vitest icon indicating copy to clipboard operation
vitest copied to clipboard

fix: importActual path resolution for non-child paths (fix #1864)

Open simon-abbott opened this issue 2 years ago • 2 comments

This fixes two similar bugs with importActual's path resolution:

  1. #1864, importing from sibling directories would try to import from sub directories instead.
  2. Importing from a sibling directory that starts with the root path would snip the root off the path (for example, path = '/foo/bar-baz' with root = '/foo/bar' results in an output of -baz)

Fixes #1864.

simon-abbott avatar Aug 17 '22 18:08 simon-abbott

Ok I have no idea why that one CI run failed. If anyone knows please let me know so I can fix it!

simon-abbott avatar Aug 17 '22 19:08 simon-abbott

@antfu Could this be merged soon? This is completely blocking my ability to convert our application over to vitest.

simon-abbott avatar Aug 22 '22 15:08 simon-abbott

@simon-abbott We might try this approach anyway. Do you think you can resolve conflicts?

sheremet-va avatar Oct 28 '22 08:10 sheremet-va

Certainly!

simon-abbott avatar Oct 28 '22 15:10 simon-abbott