upstream to js tests
Merge pull request #3684 from minggo/develop

upstream to js tests