简体   繁体   English

XCode和SenTestingKit没有输出到编辑器窗口

[英]XCode and SenTestingKit not outputting to the editor window

I am new to testing in Xcode. 我是Xcode测试的新手。 I am following the developer documentation "iOS Developement Guide" Unit Testing Applications. 我正在关注开发人员文档“iOS开发指南”单元测试应用程序。

I have successfully added unit test bundles to my application with one failing test. 我已成功将单元测试包添加到我的应用程序中,并进行了一次失败的测试。

When I build the test target the output shows 1 error as expected but the editor does not show the expected error message under the failed test. 当我构建测试目标时,输出显示预期的1错误,但编辑器未在失败的测试下显示预期的错误消息。

Does anyone know any configurations that need to be set to enable this feature? 有谁知道需要设置的任何配置才能启用此功能?

Apples docs say: "If the unit-test bundle is configured correctly, the build fails and Xcode displays an error message in the text editor." 苹果文档说:“如果单元测试包配置正确,则构建失败,Xcode在文本编辑器中显示错误消息。”

TIA TIA

Vital Clue: - One thing I have noticed in my output window is the message "Command /bin/sh failed with exit code 1" 重要线索: - 我在输出窗口中注意到的一件事是消息“命令/ bin / sh失败,退出代码为1”

Try to follow this guide Be double careful about when to set application target, and when to set Unit test target. 尝试遵循本指南要小心何时设置应用程序目标,以及何时设置单元测试目标。 It works fine for me though. 它对我来说很好。 If Unit Test fail, there should be some messages shown in the console. 如果单元测试失败,则控制台中应显示一些消息。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM