added update tests and improved the documentation