add tests for methods, improves comments.