@Test
public void shouldPushDownAllSelectNodesThatApplyToSelectorBelowAccessNodeButAboveSourceNodeUsingSameSelector() {

    // Each of the PROJECT, SELECT, and SELECT nodes must have the names of the selectors that they apply to ...
    PlanNode project = new PlanNode(Type.PROJECT, selector("Selector1"));
    PlanNode select1 = new PlanNode(Type.SELECT, project, selector("Selector1"));
    PlanNode select2 = new PlanNode(Type.SELECT, select1, selector("Selector1"));
    PlanNode select3 = new PlanNode(Type.SELECT, select2, selector("Selector1"));
    PlanNode select4 = new PlanNode(Type.SELECT, select3, selector("Selector1"));
    PlanNode access = new PlanNode(Type.ACCESS, select4, selector("Selector1"));
    PlanNode source = new PlanNode(Type.SOURCE, access, selector("Selector1"));
    // Execute the rule ...
    PlanNode result = rule.execute(context, project, new LinkedList<OptimizerRule>());
    assertThat(result, is(sameInstance(project)));
    assertChildren(project, access);
    assertChildren(access, select1);
    assertChildren(select1, select2);
    assertChildren(select2, select3);
    assertChildren(select3, select4);
    assertChildren(select4, source);
    assertChildren(source);
}