visual-studio-test-runner

.testsettings deployment section gets ignored in TFS build

半腔热情 提交于 2020-01-17 07:45:43
问题 I have a solution with bunch of C# projects with bunch of tests. Some of these tests require few native dlls (provided by related nuget packages). To address this .testsettings file was created that is copying dlls (that nuget coped to $(OutDir)) to test directory before running tests. All this works fine on local machine, but when executed under TFS Build 'deployment' section of .testsettings file (or maybe entire file) gets ignored -- these dlls never materialize in test directory (nor

How do I exclude service references from code coverage using the runsettings file in Visual Studio 2012?

人盡茶涼 提交于 2020-01-02 00:58:31
问题 I'm using a custom runsettings file to control what projects are inspected for code coverage. I used the default template provided by Microsoft and have so far been able to exclude the items I want with no issues. My next action is to exclude from code coverage the auto-generated web proxy classes that are created by Visual Studio when you add a service reference. This seemed something that should work with the default runsettings template since it has a section that looks like this:

Visual Studio 2013 is unable to open the Test Window

霸气de小男生 提交于 2019-12-28 16:45:31
问题 When I open Visual Studio 2013 and load my solution I'm greeted by an error message telling me the Test Window is unable to load. The composition produced a single composition error. The root cause is provided below. Review the CompositionException.Errors property for more detailed information. 1) Cannot compose part 'Microsoft.VisualStudio.TestWindow.Controller.TestsServiceInternal' because a cycle exists in the dependencies between the exports being composed. To break this cycle, consider

Visual Studio 2013 is unable to open the Test Window

会有一股神秘感。 提交于 2019-12-28 16:45:05
问题 When I open Visual Studio 2013 and load my solution I'm greeted by an error message telling me the Test Window is unable to load. The composition produced a single composition error. The root cause is provided below. Review the CompositionException.Errors property for more detailed information. 1) Cannot compose part 'Microsoft.VisualStudio.TestWindow.Controller.TestsServiceInternal' because a cycle exists in the dependencies between the exports being composed. To break this cycle, consider

Resharper 8.1 Test Runner slowing down Visual Studio Text Editing

坚强是说给别人听的谎言 提交于 2019-12-19 05:33:11
问题 I've got a fairly small C# solution with about 5 projects in it. I am using Visual Studio 2012 with Update 4, and Resharper 8.1 (build 8.1.23.546). It's on an I7 with an SSD and 16GB RAM, with oodles of disk space. Performance on this machine is fantastic for everything else. I have R# set to be my unit test runner, and I've noticed that as soon as I run any unit tests (one or many, pass or fail, makes no difference), the Visual Studio text editor becomes almost unusable. Typing into the

Resharper 8.1 Test Runner slowing down Visual Studio Text Editing

孤街醉人 提交于 2019-12-19 05:33:10
问题 I've got a fairly small C# solution with about 5 projects in it. I am using Visual Studio 2012 with Update 4, and Resharper 8.1 (build 8.1.23.546). It's on an I7 with an SSD and 16GB RAM, with oodles of disk space. Performance on this machine is fantastic for everything else. I have R# set to be my unit test runner, and I've noticed that as soon as I run any unit tests (one or many, pass or fail, makes no difference), the Visual Studio text editor becomes almost unusable. Typing into the

Running Remote Powershell Commandlet that wraps a process exits before completion

核能气质少年 提交于 2019-12-12 04:48:53
问题 I have a custom PowerShell commandlet that I have created in C# that spins up some instances of vstest.console.exe and publishes the test results to a .trx file or to tfs. This commandlet works in isolation when using PowerShell locally. However when I run the commandlet remotely using v3 PowerShell remoting, The invoke-command completes, but there are 2 issues: The test run process does not complete as there is no results file published I do not get the results on the remote console, whereas

How do I test a Azure AD protected Web API in with Visual Studio Test Adapter?

℡╲_俬逩灬. 提交于 2019-12-12 03:29:37
问题 I've created a multi tenant Web API that works just fine. Now I want to build a native client for testing. The Web API app is defined in one tenant. The test app is defined in another tenant that has given admin consent to the Web API. I want to use the native app to authenticate with username and password in my (non-interactive) integration tests. I cannot use certificate/app-only authentication because I need a real user context. Getting a token var userCredential = new UserCredential(

Visual studio test runner - criteria is filtering all tests

对着背影说爱祢 提交于 2019-12-11 20:24:30
问题 Using VS 2013 and TFS 2013, I have 4 unit tests but I want a TFS build to run only one of them. For this I have assigned [TestCategory("bvt")] as an attribute of the method. I edit the build definition, and within the "Add/Edit Test Run" dialog I give a value for "Test case filter:" of "TestCategory=bvt" With the filter added, no tests are executed. If I remove the filter then a team build using "ReleaseTfvcTemplate.12.xaml" result in all 4 tests being executed. I've tried wrapping the filter

Custom test adapter installed via NuGet isn't discovering tests

大兔子大兔子 提交于 2019-12-08 06:26:27
问题 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 *.TestAdapter.dll. Using that name makes vstest.console work for me when I specify /TestAdapterPath, so I'm not sure why the VS2013 test window isn't showing my tests. The adapter does work when installed by copying the relevant files to C:\Program