added coverage output to template
added extra tests and fixed the failing tests