Fix jshint warnings
Remove an unused variable and avoid a global in the tests.