Add docstrings, allow setup.py to run tests.