Merge pull request #343 from pandamicro/tests_js_3.0

Refactor #3942: Refactor singleton Class to javascript object