move js file and add js test file