-
Notifications
You must be signed in to change notification settings - Fork 284
Closed
Labels
Help-WantedThe issue is up-for-grabs, and can be claimed by commentingThe issue is up-for-grabs, and can be claimed by commenting
Description
Description
Assert.IsInstanceOfType succeeds when value is null, while the MSDN specifies it should throw an error.
AssertFailedException : 'value is null or expectedType is not found in the inheritance hierarchy of value.'
https://msdn.microsoft.com/en-us/library/ms243733.aspx
Steps to reproduce
Create a standard .net core test project from visual studio 2017, and create a dummy class. then use the following method:
public void TestMethod1() { Assert.IsInstanceOfType(null, typeof(Dummy)); }
Expected behavior
The test should throw AssertFailedException and fail
Actual behavior
The test passes
Environment
Windows Server 2016,
MSTest.Framework version 1.1.11 and 1.1.17
MSTest.TestAdapter version 1.1.11 and 1.1.17
Mertsch
Metadata
Metadata
Assignees
Labels
Help-WantedThe issue is up-for-grabs, and can be claimed by commentingThe issue is up-for-grabs, and can be claimed by commenting