Fix resize broadcaster so that components can be deregistered before rendering

Close #1245.
Add unit testing to ResizeBroadcaster registration.
keeping the svg if test fails is useless b/c it won't reveal what rendered to show what might have gone wrong