fix(TestBed): add whitespace handling to compile

Add whitespace handling to the TestBed’s compile function.

Previously, strings passed with leading or trailing
whitespace would be compiled incorrectly. Now, valid HTML
with arbitrary whitespace in and surrounding it can be
compiled properly.