added test for subroutine templates