Reputation: 34305
After running my automated tests in Visual Studio 2010, the Code Coverage Results tab shows something I don't understand. One of the classes that gets tested is called ApplicationData. It shows up in the code coverage list. But variants of it also show up, three times (see below) in this case.
If I expand each ApplicationData instance in the code coverage tab, the first shows all methods, and the rest show some methods.
My question is... What are those extra ApplicationData classes with <>c__DisplayClass appended?
Upvotes: 3
Views: 515
Reputation: 100545
These are auto-generated classes for syntactic sugar features like closures. I.e.
int v = 1;
myIntArray.Foreach( item => { v+= item; });
Will produce some class for storing/passing v
appropriately.
Upvotes: 6