We are receiving more and more issues from customers whose builds all fail on the step:
*** TEST FAILED***
This is one variant of exit code 65 but not related to CircleCI at all. This is due to weird behavior with automatic code signing which is a feature that shipped with Xcode 8.
In order to work around this please disable it in your project and set certificates manually for signing or use tools that are able to do so.