Add documentation and minor code-refactoring

`did fail` -> `failed`. This is a message in English, not one of objective-c's perverted method names.