public void CopyTo() { var copy = new KeyValuePair <string, string> [5]; _pList.CopyTo(copy, 0); Assert.All(copy.Select(c => c.Key), s => Assert.Contains(s, new [] { "prop1", "prop2", "prop3", "prop4", "prop5" })); Assert.All(copy.Select(c => c.Value), s => Assert.Contains(s, new[] { "value1", "value2", "value3", "value4", "value5" })); }