@Test public void testPushAcrossFrameWithAccessNode() throws Exception {
QueryMetadataInterface metadata = new TempMetadataAdapter(FakeMetadataFactory.example1Cached(), new TempMetadataStore());
Command command = TestOptimizer.helpGetCommand("select * from (select * from pm1.g1 union select * from pm1.g2) x where e1 = 1", metadata, null); //$NON-NLS-1$
Command subCommand = TestOptimizer.helpGetCommand("select * from pm1.g1 union select * from pm1.g2", metadata, null); //$NON-NLS-1$
RelationalPlanner p = new RelationalPlanner();
CommandContext cc = new CommandContext();
p.initialize(command, null, metadata, null, null, cc);
PlanNode root = p.generatePlan(command);
PlanNode child = p.generatePlan(subCommand);
PlanNode sourceNode = NodeEditor.findNodePreOrder(root, NodeConstants.Types.SOURCE);
sourceNode.addFirstChild(child);
sourceNode.setProperty(NodeConstants.Info.SYMBOL_MAP, SymbolMap.createSymbolMap(sourceNode.getGroups().iterator().next(), (List<SingleElementSymbol>)child.getFirstChild().getProperty(Info.PROJECT_COLS), metadata));
//add a dummy access node
PlanNode accessNode = NodeFactory.getNewNode(NodeConstants.Types.ACCESS);