void (String moduleName, String... expectedDeps) { final List<String> actual = new ArrayList<>(); getRootManager(moduleName).orderEntries().withoutSdk().withoutModuleSourceEntries().exportedOnly().process(new RootPolicy<>() { @Override public Object visitModuleOrderEntry(@NotNull ModuleOrderEntry e, Object value) { actual.add(e.getModuleName()); return null; } @Override public Object visitLibraryOrderEntry(@NotNull LibraryOrderEntry e, Object value) { actual.add(e.getLibraryName()); return null; } }, null); assertOrderedElementsAreEqual(actual, expectedDeps); }