private void compareToUDFYearDate(long t, int y) throws HiveException {
    UDFYear udf = new UDFYear();
    udf.initialize(new ObjectInspector[]{PrimitiveObjectInspectorFactory.writableTimestampObjectInspector});
    TimestampWritableV2 tsw = toTimestampWritable(t);
    IntWritable res = (IntWritable) udf.evaluate(
        new GenericUDF.DeferredObject[]{new GenericUDF.DeferredJavaObject(tsw)});
    Assert.assertEquals(res.get(), y);
  }
Input array is used to fill the entire size of the vector row batch
ql/src/test/org/apache/hadoop/hive/ql/exec/vector/expressions/TestVectorDateExpressions.java