add test and doc string