Test-driving your Javascript for fun and profit
eng.wealthfront.com
eng.wealthfront.com
OK, that is just gratuitous "magic". Nobody picking up that code to look at is going to realise that the comment is meaningful and necessary for the test. What is the advantage of doing that instead of calling a function to do the work, passing the DOM fragment as a parameter. Even if the parser that currently uses the comment has to identify the function call and treat it in the same way as the comment, at least by doing it as a function call, you have signalled to any user that the comment is significant.
/rant