capture_html helper tests

Whilst putting together #927 I noticed that the `capture_html` tag is untested