Accumplish web auto refresh

I used to believe I should render html everytime when the backend data
changes, and it came out to be wrong, tornado could dynamicly render
changing data.
I render two kinds of html, one if test is running, set an auto refresh;
the other one, thus the test stops, replace it with a <br/>