Added tests from documentation, making corrections.