add test and docstirng