CCC
CCC

Reputation: 2242

Can I run 'Unit Test App' on Windows Phone 8.1 device via Visual Studio 2015

this is my development environment,

Windows 10
Visual studio 2015 professional 

this is my target,

run unit test on the windows phone 8.1 device

this is my question,

I create empty Unit Test App (Windows Phone) Visual C++ project,

  1. I run the default empty test under Debug x86, it works on emulator.
  2. I changed x86 to ARM and connect with Windows Phone 8.1 device, it doesn't work, and display the message:

    PhoneUnitTestApp1.dll cannot be run. Please create a Windows Store or Windows Phone Unit Test project.

I don't understand the message. The project I created is Windows Phone Unit Test project already. How do I run the Unit test on the device?

Upvotes: 4

Views: 420

Answers (1)

Abhijit Annaldas
Abhijit Annaldas

Reputation: 667

Quote from the article:

When you want to unit test your app, both the tested and the test project apparently must have platform “x86”. The resulting XAP will be unit testable, and run on the emulator – but not on your phone.

When you want to deploy or submit an app, set the configuration to “Any CPU”. The resulting XAP will run on your emulator and your phone, and can > be submitted.

Check this - Looks like this is what you are exactly facing. http://dotnetbyexample.blogspot.in/2013/06/x86arm-configuration-gotcha-in-windows.html

Upvotes: 0

Related Questions