Using the default featured image code in a template file adds in the alt tag, but, what if you want to also include the title tag?
Simply add this to your functions file.
function pands_img_title($attr, $attachment = null){
$attr['title'] = get_post($attachment->ID)->post_title;
return $attr;
}
add_filter('wp_get_attachment_image_attributes', 'pands_img_title', 10, 2);