Update tests.js

fix server test environment