tidying up documentation and tests