Fixed #23768 -- Rewrote template tests as unit tests

Yes. The inline comments are comments from the original suite that applied to multiple test cases. The doc strings are the comments which applied to a single test case.

My thought was to clean these up as part of adding meaningful names to the test methods. Otherwise, I could add the inline comment as doc strings to each test it applies to. I'm open to suggestions here.