使用 iPhone MapKit 框架进行单元测试冻结测试构建
我已经在我的 iOS4.1 iPhone 应用程序上成功执行了单元测试。我目前正在尝试为使用 MapKit 框架中的 API 的部分逻辑添加一些测试。
一旦我将 MapKit 框架添加到我的 LogicTest 目标中,目标就不会编译——编译过程就会挂起。即使我没有测试、启动或拆卸逻辑,也会发生这种情况。我认为在将 MapKit 框架添加到单元测试构建时我可能缺少一些设置。
有趣的补充:如果我将基础 SDK 更改为 3.2,则目标在编译期间不会挂起(尽管会出现错误,因为我使用的是 4.0 的 API)。
I have been performing unit tests on my iOS4.1 iPhone app successfully. I am currently trying to add some tests for a portion of my logic that uses APIs from the MapKit framework.
As soon as I add the MapKit framework to my LogicTest target, the target will not compile -- the compile process just hangs. This occurs even if I have no tests, startup or teardown logic. I think I might be missing some setting when adding the MapKit framework to a unit test build.
Interesting addition: if I change my base SDK to 3.2, the target will not hang during the compile (although, there will be errors because I am using API from 4.0).
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我一直在尝试与我的单元测试目标相关的框架。我添加了所有框架,它不再挂起。然后我尝试将这些框架一一删除,看看需要哪个框架以及 MapKit ——猜猜看——问题就消失了。我无法再重新创建它。
I kept playing around with the frameworks associated with my unit test target. I added all of the frameworks, and it stopped hanging. Then I tried removing the frameworks one-by-one to see which one was needed along with the MapKit -- guess what -- the problem went away. I can no longer re-create it.
我有同样的问题。我确实添加了所有框架并且它有效。您是否尝试在删除不需要的框架后进行干净的构建?
I had the same issue. I did add all the frameworks and it worked. Did you try doing a clean build after removing the unwanted frameworks?