update docs, add some more tests