Test utils fixes

Just tidying up some things in webgl-test-utils.js, should not affect behavior of existing tests at all.