Linq select new Not Covered %100 in Unit test
Hi Everyone, In unit tests linq select not cover exactly, ı am shared two picture downside. First one result of foreach and select new coverage result. It is exactly made same job. foreach cover %100 but linq select not Second Picture is about record…
![](https://techprofile.blob.core.windows.net/images/9b93715d1d2a4925a4c5f343dfd513e7.jpeg)
How can I call a method of the original class from the its fake class method
I created a fake assembly called MyProject.Web.Customer.Fakes from the project MyProject.Web.Customer. I am trying to call Read method of the MyProject.Web.Customer from its fake object from the test method.The fake class there is a method I have given…
How to execute e2e test in visual studio
Hello, I want to know how to execute e2e test in VS 2022 Check the screen shot above.
Gabled characters produced by Visual Studio 2022
Recently, I started working for migration of my software from Visual Studio 2008 to 2022. After a lot of difficulties with the new IDE, I succeeded in generating the .exe files without errors, one for "Release" version and the other for…
Best way to unit test cancellation
Good evening. I have been trying to write a unit test that will test the cancellation of a method. Now I have a unit test written that passes, but I am do not think it is what I am looking to achieve. I have tried a few different ways to achieve the…
TypeLoadException with different NLog versions in MSTest
Hi, I have a project A (an application) which includes a package B, which in turn contains a third party package C3, which in turn contains another third party package package D3. Both packages A and D3 use the same third party package NLog but with…
Visual Studio 2019 web recorder greyed out on load test
Hello, I've installed Visual Studio 2019 Enterprise on a server, and currently, I only get the web recorder not greyed out when I run the test with the user account I installed visual studio with. This account is local admin. But when try to run it…
Getting build error after selecting "automatically deploy the database project before unit tests are run" checkbox in SSDT visual studio 2022
In new visual studio update “Microsoft Visual Studio Community 2022 (64-bit) - Current Version 17.4.3”, After selecting the “automatically deploy the database project before unit tests are run” checkbox in SQL Server Test Configuration, when I tried…
how to use text files to run tests
hi i would like to know hoe can i use text files to run tests us it posible to use the as input and expected output? is so haw is it done in VS 2022?
Unit testing C++ CLR
What is the best approach to write Unit Tests for C++/CLR? We have a solution that includes C++ native, C++/CLR and C#.Net code. When I try to add a C++/CLR reference to a C#.net Unit Test project, it compiles, but when I run the tests it says…
How to write Unit test for DAL which call stored procedure and direct sql commands
Hello Everyone, I am writing unit test cases(using xunit) for DAL methods(which are calling stored procedures and some direct sql commands and not returning methods). How can I mock the results coming from db in unit tests. public class…
error System.Data.SqlClient.SqlException: 'Incorrect syntax near '´'.' in VB.NET (Windows Forms)
Im on vb.net framework version 4.8.1 Using an online database code Public Class register Private cmd As SqlCommand Private Sub register_btn_Click(sender As Object, e As EventArgs) Handles register_btn.Click Dim con As New…
Compile error when adding Xamarin iOS app to solution with .NET 6 NUnit test project
This came up as a result of attempting to upgrade our test projects from .NET Core 3.1 to .Net 6 in our solution that includes a Xamarin iOS app. It happens on the macOS-11 build agent in azure dev ops and also on my development mac running Visual Studio…
Microsoft.CodeCoverage.Console.exe don't remove C++ compile time code
Hello, I generate C++ code coverage with Microsoft.CodeCoverage.Console.exe. I have the following code : template<typename type_t> [[nodiscard]] static constexpr type_t* allocate_array(const usize count) noexcept…
uwp code coverage does not take effect
I created a UWP project and then created a UWP Unit Test. Running all tests is normal, but Analyze Code Coverage for All Tests is invalid and the result is 0 What can I do?
Can't run vstest
Hello all, I try to automate the UnitTests for our Azure Build Pipeline, but getting this error: Starting: Test run for Test plans ============================================================================== Task : Visual Studio…
Unable to see Intellitest dropdown in Visual Studio 2022
TL&DR Running Visual Studio Enterprise 2022 for Windows 10 Home [See ScreenShot] Created Library for Dotnet 6 (ClassLibrary2) Created Library Test for Dotnet 6 (ClassLibrary2Tests) No Intellitest Drop Down Dear Internet, …
UWP Unit Test can not connect to test process.
I have a UWP project LenovoVision that has two reference libraries CameraConfiguration and Lenovovision.Core. Now I create a UWP Unit Test project that references the above three projects. When I click Run All Tests under Test, the output…
Net Core 6: Microsoft Fakes and WPF Issue
Hello, I hope I posted in the correct forum... I'm in the progress of migrating our WPF from .Net 4.7.2 to .Net Core 6 I run into issues with our test projects that reference WPF and use Microsoft Fakes Please see my demo repo here: …
Query regarding App Centre Test Subscription
Does App Centre Test subscription ($99) includes build and distribute features as well ? Please clarify