private KeyValuePair <string, string?> ReadStringString( ulong elementAddress, ClrInstanceField keyField, ClrInstanceField valueField) { var key = keyField.ReadString(elementAddress, true); var value = valueField.ReadString(elementAddress, true); return(new KeyValuePair <string, string?>(key !, value)); }
public ClrInstanceField TestFieldNameAndValue(ClrType type, ulong obj, string name, string value) { ClrInstanceField field = type.GetFieldByName(name); Assert.NotNull(field); Assert.Equal(name, field.Name); string str = field.ReadString(obj, interior: false); Assert.Equal(value, str); return(field); }