@Test
void map() {

    var a = Literal.<String>builder("a").then(Literal.<String>builder("b").requires(val -> false).build()).build();
    var c = Literal.<String>builder("c").redirect(a).build();
    var d = Literal.<String>builder("d").then(c).build();
    
    
    root.addChild(a);
    root.addChild(c);
    root.addChild(d);
    
    var mapped = tree.map(root, "");
    var empty = mapped.getChild("a");
    var same = mapped.getChild("d").getChild("c");
    
    assertEquals("", mapped.getName());
    assertEquals(0, empty.getChildren().size());
    assertSame(empty, mapped.getChild("c").getRedirect());
    assertSame(mapped.getChild("c"), same);
}