void () { final FacetLibrariesValidatorImpl validator = createValidator(FAST_UTIL, JUNIT); assertError(""); ModuleRootModificationUtil.addModuleLibrary(myModule, myFastUtilJar.getUrl()); myValidatorsManager.validate(); assertError("junit"); ModuleRootModificationUtil.addModuleLibrary(myModule, myJUnitJar.getUrl()); myValidatorsManager.validate(); validator.onFacetInitialized(createFacet()); final List<VirtualFile> classpath = Arrays.asList(OrderEnumerator.orderEntries(myModule).getClassesRoots()); assertTrue(classpath.contains(myFastUtilJar)); assertTrue(classpath.contains(myJUnitJar)); }