简体   繁体   English

在Windows Phone 7模拟器上模拟连接flakiness进行测试

[英]simulating connection flakiness on windows phone 7 simulator for testing

I am developing an application for windows phone 7. Now for testing my application on simulator. 我正在开发Windows Phone 7的应用程序。现在在模拟器上测试我的应用程序。 I want that simulator should have connection flakiness as we usually have on wp7 device.How can I achieve this please help. 我希望模拟器应该像我们通常在wp7设备上一样具有连接片状。如何实现这一点请帮助。

Windows Phone 8.0 SDK supports network simulation . Windows Phone 8.0 SDK支持网络模拟 You can simulte 2G/3G/Wifi and no network. 你可以同步2G / 3G / Wifi,没有网络。

Unfortunately, it's not possible to test the internet connection from the emulator. 不幸的是,无法从模拟器测试互联网连接。

You absolutely have to test it from a device... 你必须从设备上测试它...

The function "NetworkInterface.GetIsNetworkAvailable()" check if the smartphone is connected to the internet. 功能“NetworkInterface.GetIsNetworkAvailable()”检查智能手机是否已连接到互联网。 However, this function will always return true since the emulator. 但是,此函数将始终从仿真器返回true。

I m not sure what are you asking for but take a look at this 我不确定你要求的是什么,但看看这个

http://www.diaryofaninja.com/blog/2010/12/09/checking-for-network-connectivity-in-windows-phone-7-sdk http://www.diaryofaninja.com/blog/2010/12/09/checking-for-network-connectivity-in-windows-phone-7-sdk

Hope it helps. 希望能帮助到你。

我只需要打开以太网电缆即可“模拟”薄片状。

My solution is to test things on a train to and from work. 我的解决方案是在火车上下班测试。 I gain & loose internet connectivity 3 or 4 times in my journey so it is ideal for me :) 我在旅程中获得了3到4次互联网连接,因此它非常适合我:)

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

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