Search in sources :

Example 1 with MockVirtualLink

use of com.intellij.mock.MockVirtualLink in project intellij-community by JetBrains.

the class VirtualFileVisitorTest method link.

private static void link(@NotNull String targetPath, @NotNull String linkPath) {
    VirtualFile target = myRoot.findFileByRelativePath(targetPath);
    assertNotNull(targetPath, target);
    int pos = linkPath.lastIndexOf('/');
    VirtualFile linkParent = myRoot.findFileByRelativePath(linkPath.substring(0, pos));
    assertNotNull(linkPath, linkParent);
    ((MockVirtualFile) linkParent).addChild(new MockVirtualLink(linkPath.substring(pos + 1), target));
}
Also used : MockVirtualFile(com.intellij.mock.MockVirtualFile) MockVirtualFile(com.intellij.mock.MockVirtualFile) MockVirtualLink(com.intellij.mock.MockVirtualLink)

Aggregations

MockVirtualFile (com.intellij.mock.MockVirtualFile)1 MockVirtualLink (com.intellij.mock.MockVirtualLink)1