-
Notifications
You must be signed in to change notification settings - Fork 324
TdsParserStateObject.ResetSnapshot() Debug.Assert failing #3385
Copy link
Copy link
Labels
Area\TestsIssues that are targeted to tests or test projectsIssues that are targeted to tests or test projects
Description
Failure is here:
/home/paul/dev/SqlClient/dev/paul/app-context-switch-test-helper/src/Microsoft.Data.SqlClient/src/Microsoft/Data/SqlClient/TdsParserStateObject.cs(3441): error TESTERROR:
Microsoft.Data.SqlClient.ManualTesting.Tests.DataReaderTest.CanReadXmlData (354ms): Error Message: Microsoft.VisualSt
udio.TestPlatform.TestHost.DebugAssertException : Method Debug.Fail failed with 'snapshot._storage == null
', and was translated to Microsoft.VisualStudio.TestPlatform.TestHost.DebugAssertException to avoid terminating the p
rocess hosting the test.
Here's the code:
if (_snapshot != null)
{
StateSnapshot snapshot = _snapshot;
_snapshot = null;
Debug.Assert(snapshot._storage == null);
snapshot.Clear();
Interlocked.CompareExchange(ref _cachedSnapshot, snapshot, null);
}
@Wraith2 I'm not sure what the intention of the Assert() is.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Area\TestsIssues that are targeted to tests or test projectsIssues that are targeted to tests or test projects