public void testArithmeticOpCastInsert1() throws Throwable {
LogicalExpressionPlan plan = new LogicalExpressionPlan() ;
ConstantExpression constant1 = new ConstantExpression(plan, 10) ;
ConstantExpression constant2 = new ConstantExpression(plan, 20D) ;
MultiplyExpression mul1 = new MultiplyExpression(plan,constant1, constant2) ;
// Before type checking its set correctly - PIG-421
// System.out.println(DataType.findTypeName(mul1.getType())) ;
// assertEquals(DataType.DOUBLE, mul1.getType()) ;
CompilationMessageCollector collector = new CompilationMessageCollector() ;
TypeCheckingExpVisitor expTypeChecker = new TypeCheckingExpVisitor(plan, collector, null);
expTypeChecker.visit();
printMessageCollector(collector) ;
//printTypeGraph(plan) ;
// After type checking
System.out.println(DataType.findTypeName(mul1.getType())) ;
assertEquals(DataType.DOUBLE, mul1.getType()) ;
}