Visual Studio For Mac Tests Not Running

admin
Visual Studio For Mac Tests Not Running Average ratng: 5,8/10 3123 reviews

Steps to reproduce • Create a.NET Core app project (e.g. MyUnitTestProj) • Create another.NET Core app project (e.g. MySharedUnitTestCodeProj) • Add NuGet package references to 'xunit' and 'xunit.runner.visualstudio', to the second.NET Core app project only (MySharedUnitTestCodeProj) • Add a project reference from the first project to the second one.

Running tests with dotnet test or with VS 2017 on Windows works fine. To duplicate, create a new xUnit test project in VS for MAC (.net core 2.0). It will have the following nuget packages. The purple run indicator means something has not finished and is still running. For example, if I create a test class that when the fixture finishes does a Thread.Sleep the tests are red, green, the class is marked as running, purple run icon, since it has not finished, until the sleep finishes.

In other words, have MyUnitTestProj reference MySharedUnitTestCodeProj. • MyUnitTestProj now has a reference to xUnit indirectly, via the other project.

Add some test classes and test methods using the [Xunit.Fact] attribute. • Build the solution Expected behavior • The unit tests you created in MyUnitTestProj show up in the unit tests pad on Visual Studio for Mac Actual behavior • No unit tests appear in the unit tests pad of Visual Studio for Mac Additional information • This is a problem specific to Visual Studio for Mac. The problem does not occur with Visual Studio for Windows, i.e. The unit tests show up in Visual Studio for Windows just fine.

Keyboard Shortcuts For Windows and Mac Keyboard shortcuts are often used in modern operating systems and computer software programs. Using keyboard shortcuts could save you a lot of time. Shortcut for 1/8 in word machine.

Sample project demonstrating the problem • • Open the sln included in the zip file above in Visual Studio for Mac and build. Open the unit tests pad. Contrast the results with Visual Studio for Windows. Notice that in Visual Studio for Mac, 'TestProjectWithDirectReferenceToXUnit' shows unit tests, but 'TestProjectWithIndirectReferenceToXUnit' does not show unit tests. On Windows both projects show unit tests.