public List<String> sort() {
        for (String strN : map.keySet()) {
            visit(strN);
        }
        return result;
    }
@Test
    public void simple() {
        ImportUnit a = create("a");
        ImportUnit b = create("b", "a");
        ImportUnit c = create("c", "b");

        Map<String, ImportUnit> importUnits = new HashMap<>();
        importUnits.put("a", a);
        importUnits.put("b", b);
        importUnits.put("c", c);

        ImportUnitSorter sorter = new ImportUnitSorter(importUnits);
        List<String> sorted = sorter.sort();

        assertEquals(importUnits.size(), sorted.size());
        assertEquals(List.of("a", "b", "c"), sorted);
    }