try {
buildPlan(" a = load '1.txt' as (a0:int, a1:int);");
LogicalPlan lp = buildPlan(" b = foreach a generate a0, a1 as a0;");
SchemaAliasValidator schemaAliasValidator = new SchemaAliasValidator() ;
CompilationMessageCollector collector = new CompilationMessageCollector() ;
schemaAliasValidator.validate(lp, collector);
} catch (PlanValidationException e) {
assertTrue(e.getCause().getMessage().contains("Duplicate schema"));
return;
}
fail();