adding tests and example