added tests and updated package.json