void () { LibraryTable table = getProjectLibraryTable(); Library library = WriteAction.compute(() -> table.createLibrary("native")); Library.ModifiableModel model = library.getModifiableModel(); model.addRoot("file://native-lib-root", NativeLibraryOrderRootType.getInstance()); commit(model); assertThat(serializeLibraries(myProject)).isEqualTo( """ <library name="native"> <CLASSES /> <JAVADOC /> <NATIVE> <root url="file://native-lib-root" /> </NATIVE> <SOURCES /> </library>""" ); }