Questions tagged [visual-studio-test-runner]

Microsoft Visual Studio 2012 (and later) provides an open framework that allows 3rd parties to integrate their test frameworks into the Visual Studio and Team Build experience.

The program name is VSTest.Console.Exe.

Suppose to replace MSTest. See comparison at https://msdn.microsoft.com/en-us/library/ms253138(v=vs.110).aspx#Runner

74 questions
1
vote
1 answer

How can I unit test a 64-bit .NET 4.7 project?

I first got a BadImageFormatException in my test project and after some research it seemed that it was caused because the test project had a AnyCPU build, while the project I want to test had a 64-bit build. After changing my test project to 64 bit…
1
vote
2 answers

Error running tests in Visual Studio 2017: No process is on the other end of the pipe

Sometimes when I run my tests (.Net Standard 2.0 project using XUnit) I get an error in the Tests output pane saying: [25.09.2018 1:46:36 Error] System.IO.IOException: No process is on the other end of the pipe." And then I can't run the tests any…
1
vote
1 answer

How can I set Expecto configuration properties when running tests via Visual Studio test adapter

I'm using Expecto.VisualStudio.TestAdapter to integrate with Visual Studio 2017. How do I set configuration options for Expecto so that the Visual Studio test runner will pick them up? I specifically need to set parallel = false for a given test…
Coding Dude
  • 617
  • 1
  • 6
  • 16
1
vote
1 answer

XUnit tests running fast in VS2017 but very slowly on VSTS build agent

I've recently migrated ~2000 pure unit tests from MSTest to XUnit. The tests are contained in approximately 10 tests projects and are configured to run in parallel by test collection and assembly. I've installed the visual studio test runner nuget…
ASH
  • 573
  • 2
  • 7
  • 20
1
vote
1 answer

How do I programmatically pause a unittest?

I'm using visual-studio built-in unit-testing framework - Microsoft.VisualStudio.TestTools.UnitTesting namespace. I need to pause unit-test execution from the test code (and, preferably, allow the developer to resume the test by pressing some button…
jazzcat
  • 4,351
  • 5
  • 36
  • 37
1
vote
2 answers

Execute Visual Studio Test Runner in Parallel on Team Foundation Server

I have a few test sets in a single TFS build definition. I'm looking for a way to run all my tests sets in parallel to cut down on the time that the build takes to run. Below is a screen shot of my build definition and my automated test…
TWilly
  • 4,863
  • 3
  • 43
  • 73
1
vote
1 answer

Test Runner can't find controls during replay

I just started with Microsoft Test Manager 2015 and build two test cases. First one involves clicking on a tray icon and selecting an entry from there - which works fine. Second case is a bit more complex, I wanted to fill out a form in a WPF window…
Steffen Winkler
  • 2,805
  • 2
  • 35
  • 58
1
vote
1 answer

Visual Studio 2013 cannot find Ms Test.exe for Test Runner, only VsTest available

In VS 2013 there seems to be no option to select MSTest instead of VsTest in the Test Runner Dropdown which is also grayed out. Is there a way I can add Mstest to this list as was the case in Vs 2010.
1
vote
0 answers

NUnit Testing with visual studio - how can I throw exception at point of failure?

I'm trying to write some tests in NUnit and running them through the VS Test Explorer. If my test code throws an exception it seems it is just swallowed up, even when I run the test in Debug mode. For example, if a NullReferenceException happens in…
parliament
  • 21,544
  • 38
  • 148
  • 238
1
vote
1 answer

Custom test adapter installed via NuGet isn't discovering tests

I'm trying to install a custom test adapter via NuGet, but it seems like VS isn't recognizing it. I've looked through the code in Microsoft.VisualStudio.TestWindow.VsAdapters.UnitTestExtensionDiscoverer, so I've realized the dll has to end with…
1
vote
0 answers

nUnit Test Runner - Test stays in "Not run" if it takes over a certain amount of time

We have some Selenium tests built with nUnit that take quite a while to complete. We are finding that they stay in the "Not run tests" grouping even though they should pass. After some initial investigation we found that if we remove some long…
1
vote
1 answer

Windows Phone 8 Unit Test creating a bitmapimage

I have a method that takes a BitmapImage. I am trying to test it by creating or loading a BitmapImage and then passing it to said method. However, unit test does not allow me to create a bitmapimage, it throws an InvalidCrossThreadException. Is…
1
vote
1 answer

How to capture Test Case ID that's current being run in the MTM in C# test method

How to capture Current Test Case ID that's current being run in the MTM pragmatically using C# code? Thanks & Regards, woodson
1
vote
1 answer

How can I run VS2012 CppUnitTestFramework unit tests from an msbuild script?

I've written a native unit test dll that uses VS2012's CppUnitTestFramework. I can run these tests in the VS2012's IDE in the Test Explorer window. But, I'd like to also run these tests from our MsBuild script. I guess I need to launch some test…
0
votes
0 answers

Run only selective tests on AzureDevops Server 2022 based on Pull-Request

I have Azure DevOps Server 2022 and I have a Visual Studio C# Soulution in the repoistory. Is it possible after creating pull request, based on the Tags provided (see picture bellow), run only the tests, that matches the Tag with the…