void (final String vcsName) { ProjectLevelVcsManager vcsManager = ProjectLevelVcsManager.getInstance(myProject); vcsManager.setDirectoryMapping(myWorkingCopyDir.getPath(), vcsName); AbstractVcs vcs = vcsManager.findVcsByName(vcsName); Assert.assertEquals(1, vcsManager.getRootsUnderVcs(vcs).length); }