在iphone模拟器上的wifi [英] wifi on iphone simulator

查看:348
本文介绍了在iphone模拟器上的wifi的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我可以在iphone simultaor中禁用wifi来测试我的应用程序吗?
我从网络断开电脑,但iphone模拟器上的wifi图标始终打开。

can i disable wifi in iphone simultaor to test my app? I disconnect pc from network, but the icon of wifi on iphone simulator is always on.

推荐答案

禁用后网络连接,图标仍然显示为已启用,但连接当然已死。如果您正在使用Reachability类或仅尝试ping URL以验证连接,则模拟器将以与禁用Wifi的设备相同的方式响应,这使得在这些条件下在模拟器上进行的测试非常准确。

After disabling your network connection, the icon is still present showing it as enabled, but the connection is of course dead. If you are using the Reachability class or just attempting to ping a URL to verify a connection, the simulator will respond the same way a device with disabled Wifi would, which makes testing on the simulator under these conditions pretty accurate.

这篇关于在iphone模拟器上的wifi的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆