Changes to templates; added test for real this time.