I am using the XUnit framework to write unit test cases for my Grasshopper plugin. When I run the test cases individually, they execute properly. However, when I try to run them together, most of the test cases fall into the category of “Not Run.” I am using the RhinoDoc.CreateHeadless()
method to create a few objects and initialize RhinoDoc.ActiveDoc
, as my project fetches data from ActiveDoc
.
I am disposing RhinoDoc.ActiveDoc properly after each method .
Additionally, when running all the test cases together, some fail with the error:
" System.AccessViolationException : Attempted to read or write protected memory. This is often an indication that other memory is corrupt."
The error occurs on the line RhinoDoc.CreateHeadless()
.