Tests: Fix errors and visual glitches seen in Chrome

Closes gh-7508
Fixes gh-7499