void () { final JpsLibrary library = myProject.addLibrary("l", JpsJavaLibraryType.INSTANCE); final JpsLibraryReference reference = library.createReference().asExternal(myModel); assertEquals("l", reference.getLibraryName()); assertSame(library, reference.resolve()); }