1 write to _dataGridViewComboBoxCell
System.Windows.Forms.Tests (1)
System\Windows\Forms\DataGridViewComboBoxCellTests.cs (1)
16
_dataGridViewComboBoxCell
= new();
56 references to _dataGridViewComboBoxCell
System.Windows.Forms.Tests (56)
System\Windows\Forms\DataGridViewComboBoxCellTests.cs (56)
13
public void Dispose() =>
_dataGridViewComboBoxCell
.Dispose();
20
_dataGridViewComboBoxCell
.AutoComplete.Should().BeTrue();
25
_dataGridViewComboBoxCell
.AutoComplete = false;
26
_dataGridViewComboBoxCell
.AutoComplete.Should().BeFalse();
31
_dataGridViewComboBoxCell
.DataSource.Should().BeNull();
37
_dataGridViewComboBoxCell
.DataSource = list;
38
_dataGridViewComboBoxCell
.DataSource.Should().BeSameAs(list);
45
_dataGridViewComboBoxCell
.DataSource = bindingSource;
47
_dataGridViewComboBoxCell
.DataSource.Should().BeSameAs(bindingSource);
53
Exception? invalidDataSourceException = Record.Exception(() =>
_dataGridViewComboBoxCell
.DataSource = 123);
61
_dataGridViewComboBoxCell
.DataSource = new List<string> { "a" };
62
_dataGridViewComboBoxCell
.DisplayMember = "Name";
63
_dataGridViewComboBoxCell
.ValueMember = "Id";
64
_dataGridViewComboBoxCell
.DataSource = null;
66
_dataGridViewComboBoxCell
.DataSource.Should().BeNull();
67
_dataGridViewComboBoxCell
.DisplayMember.Should().BeEmpty();
68
_dataGridViewComboBoxCell
.ValueMember.Should().BeEmpty();
73
_dataGridViewComboBoxCell
.DisplayStyleForCurrentCellOnly.Should().BeFalse();
77
_dataGridViewComboBoxCell
.DropDownWidth.Should().Be(1);
84
_dataGridViewComboBoxCell
.DropDownWidth = width;
85
_dataGridViewComboBoxCell
.DropDownWidth.Should().Be(width);
93
Exception? dropDownWidthOutOfRangeException = Record.Exception(() =>
_dataGridViewComboBoxCell
.DropDownWidth = width);
100
_dataGridViewComboBoxCell
.FlatStyle.Should().Be(FlatStyle.Standard);
109
_dataGridViewComboBoxCell
.FlatStyle = style;
110
_dataGridViewComboBoxCell
.FlatStyle.Should().Be(style);
115
_dataGridViewComboBoxCell
.MaxDropDownItems.Should().Be(DataGridViewComboBoxCell.DefaultMaxDropDownItems);
123
_dataGridViewComboBoxCell
.MaxDropDownItems = value;
124
_dataGridViewComboBoxCell
.MaxDropDownItems.Should().Be(value);
134
Exception? maxDropDownItemsOutOfRangeException = Record.Exception(() =>
_dataGridViewComboBoxCell
.MaxDropDownItems = value);
141
_dataGridViewComboBoxCell
.Sorted.Should().BeFalse();
146
_dataGridViewComboBoxCell
.Sorted = true;
147
_dataGridViewComboBoxCell
.Sorted.Should().BeTrue();
153
_dataGridViewComboBoxCell
.DataSource = new List<string> { "a", "b" };
155
Exception? sortedWithDataSourceException = Record.Exception(() =>
_dataGridViewComboBoxCell
.Sorted = true);
162
_dataGridViewComboBoxCell
.ValueMember.Should().BeEmpty();
170
_dataGridViewComboBoxCell
.ValueMember = value;
171
_dataGridViewComboBoxCell
.ValueMember.Should().Be(value);
176
_dataGridViewComboBoxCell
.ValueType.Should().Be(typeof(object));
203
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.DisplayMemberProperty = prop;
204
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.ValueMemberProperty = null;
206
_dataGridViewComboBoxCell
.ValueType.Should().Be(typeof(string));
216
Rectangle result =
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.GetContentBounds(g, style, 0);
225
using DataGridViewComboBoxColumn column = new() { CellTemplate =
_dataGridViewComboBoxCell
};
231
Rectangle result =
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.GetContentBounds(g, style, -1);
243
Rectangle result =
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.GetErrorIconBounds(g, style, 0);
252
using DataGridViewComboBoxColumn column = new() { CellTemplate =
_dataGridViewComboBoxCell
};
258
Rectangle result =
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.GetErrorIconBounds(g, style, -1);
270
Size result =
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.GetPreferredSize(
309
bool result =
_dataGridViewComboBoxCell
.KeyEntersEditMode(e);
317
using DataGridViewComboBoxColumn column = new() { CellTemplate =
_dataGridViewComboBoxCell
};
321
object? result =
_dataGridViewComboBoxCell
.ParseFormattedValue(
334
using DataGridViewComboBoxColumn column = new() { CellTemplate =
_dataGridViewComboBoxCell
};
339
_dataGridViewComboBoxCell
.TestAccessor().Dynamic.ValueMemberProperty = prop;
341
object? result =
_dataGridViewComboBoxCell
.ParseFormattedValue("abc", style, null, null);
350
using DataGridViewComboBoxColumn column = new() { CellTemplate =
_dataGridViewComboBoxCell
};
354
object? result =
_dataGridViewComboBoxCell
.ParseFormattedValue("test", style, null, null);