fix Unit Testing and lint js file