Skip to content

Instantly share code, notes, and snippets.

@dotMorten
Created September 29, 2018 03:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dotMorten/dbae5835830aa1a9d12f38ee5053651d to your computer and use it in GitHub Desktop.
Save dotMorten/dbae5835830aa1a9d12f38ee5053651d to your computer and use it in GitHub Desktop.
Run UWP Unit Tests
REM Build project
msbuild /restore /t:Build /p:Platform=x64;Configuration=Debug MyUWPTestProject.csproj
REM Remove previous install
Powershell.exe -command "& {Remove-AppxPackage -Package 'd160b1a9-2c65-41ed-82af-4d4939e99742_1.0.0.0_x64__zy2ctb9gr90we'}"
REM Install cert. Note: Must be run with elevated (admin) access
certutil -addstore root "AppPackages\MyUWPTestProject_1.0.0.0_x64_Debug_Test\MyUWPTestProject_1.0.0.0_x64_Debug.cer"
REM Run Tests
VSTest.Console MyUWPTestProject\AppPackages\MyUWPTestProject_1.0.0.0_x64_Debug_Test\MyUWPTestProject_1.0.0.0_%x64_Debug.appx /logger:trx;LogFileName=TestReport.TRX /Platform:x64 /InIsolation /framework:FrameworkUap10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment