fix package dependencies, add test.