more tests and minor doc changes