Add UT and function for templating data