add some tests
docstrings, tests and demo