Update errors_tests.js

Updated test to reflect API change.