194 references to ConvertTo
Microsoft.AspNetCore.Http.Abstractions.Tests (1)
PathStringTests.cs (1)
295
Assert.Equal("/foo", converter.
ConvertTo
(result, typeof(string)));
Microsoft.Maui.Controls (1)
TypeConversionHelper.cs (1)
55
convertedValue = converter.
ConvertTo
(value, targetType) ?? throw new InvalidOperationException($"The {converter.GetType()} returned null when converting {valueType} to {targetType}");
PresentationCore.Tests (3)
System\Windows\DurationConverter.Tests.cs (1)
73
Assert.Throws<ArgumentNullException>(() => converter.
ConvertTo
(new Duration(new TimeSpan(17, 22, 10, 15, 457, 123)), destinationType: null!));
System\Windows\Input\MouseActionConverter.Tests.cs (2)
153
Assert.Throws<ArgumentNullException>(() => converter.
ConvertTo
(MouseAction.None, destinationType: null!));
166
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
PresentationFramework (2)
System\Windows\Controls\ContentPresenter.cs (1)
1020
e = (UIElement) tc.
ConvertTo
(content, typeof(UIElement));
System\Windows\Markup\Primitives\ElementMarkupObject.cs (1)
808
value = converter.
ConvertTo
(expression, typeof(MarkupExtension));
System.Drawing.Common.Tests (18)
System\Drawing\FontConverterTests.cs (1)
121
InstanceDescriptor descriptor = (InstanceDescriptor)converter.
ConvertTo
(font, typeof(InstanceDescriptor));
System\Drawing\IconConverterTests.cs (6)
136
Assert.Equal(_iconStr, (string)_icoConv.
ConvertTo
(_icon, typeof(string)));
141
newIconBytes = (byte[])_icoConv.
ConvertTo
(_icon, _iconBytes.GetType());
153
Assert.Equal(_iconStr, (string)_icoConvFrmTD.
ConvertTo
(_icon, typeof(string)));
158
newIconBytes = (byte[])_icoConvFrmTD.
ConvertTo
(_icon, _iconBytes.GetType());
171
Assert.Equal("(none)", (string)_icoConv.
ConvertTo
(null, typeof(string)));
174
Assert.Equal("(none)", (string)_icoConvFrmTD.
ConvertTo
(null, typeof(string)));
System\Drawing\ImageConverterTests.cs (6)
158
Assert.Equal(_imageStr, (string)_imgConv.
ConvertTo
(_image, typeof(string)));
160
Assert.Equal(_imageStr, (string)_imgConvFrmTD.
ConvertTo
(_image, typeof(string)));
164
Assert.Equal("(none)", (string)_imgConv.
ConvertTo
(null, typeof(string)));
167
Assert.Equal("(none)", (string)_imgConvFrmTD.
ConvertTo
(null, typeof(string)));
181
newImageBytes = (byte[])_imgConvFrmTD.
ConvertTo
(_image, _imageBytes.GetType());
190
byte[] converted = (byte[])converter.
ConvertTo
(value, typeof(byte[]));
System\Drawing\ImageFormatConverterTests.cs (4)
131
Assert.Equal(_imageFmtStr, (string)_imgFmtConv.
ConvertTo
(_imageFmt, typeof(string)));
134
Assert.Equal(_imageFmtStr, (string)_imgFmtConvFrmTD.
ConvertTo
(_imageFmt, typeof(string)));
136
Assert.Equal(string.Empty, (string)_imgFmtConv.
ConvertTo
(null, typeof(string)));
139
Assert.Equal(string.Empty, (string)_imgFmtConvFrmTD.
ConvertTo
(null, typeof(string)));
System\Drawing\Printing\MarginsConverterTests.cs (1)
143
Assert.Equal(string.Empty, (string)mc.
ConvertTo
(null, typeof(string)));
System.Windows.Controls.Ribbon (1)
Microsoft\Windows\Controls\Ribbon\RibbonHelper.cs (1)
1557
DynamicResourceExtension dynamicResource = _rreConverter.
ConvertTo
(expr, typeof(MarkupExtension)) as DynamicResourceExtension;
System.Windows.Forms (5)
System\Resources\ResXDataNode.cs (1)
268
byte[]? data = (byte[]?)converter.
ConvertTo
(value, typeof(byte[]));
System\Windows\Forms\ComponentModel\COM2Interop\Com2PropertyDescriptor.Com2PropDescMainConverter.cs (1)
43
? baseConverter.
ConvertTo
(value, destinationType)
System\Windows\Forms\Controls\DataGridView\DataGridView.DataConnection.cs (1)
1484
value = valueConverter.
ConvertTo
(value, columnType);
System\Windows\Forms\DataBinding\Binding.cs (2)
724
return typeConverter.
ConvertTo
(value, type);
798
return typeConverter.
ConvertTo
(value, type);
System.Windows.Forms.Design (3)
System\ComponentModel\Design\Serialization\CodeDomSerializerBase.cs (2)
1891
if (converter.
ConvertTo
(value, typeof(InstanceDescriptor)) is InstanceDescriptor descriptor && descriptor.MemberInfo is not null)
1903
if (converter.
ConvertTo
(value, typeof(InstanceDescriptor)) is InstanceDescriptor descriptor && descriptor.MemberInfo is not null)
System\ComponentModel\Design\Serialization\EnumCodeDomSerializer.cs (1)
38
values = (Enum[])converter.
ConvertTo
(enumValue, typeof(Enum[]))!;
System.Windows.Forms.Design.Tests (3)
System\Resources\Tools\StronglyTypedResourceBuilderTests.cs (3)
330
ResXDataNode node = new("Image1", converter.
ConvertTo
(bitmap, typeof(byte[])));
410
ResXDataNode node = new("Icon1", converter.
ConvertTo
(icon, typeof(byte[])));
622
ResXDataNode node = new("MediaPlayer1", converter.
ConvertTo
(mediaPlayer.OcxState, typeof(byte[])));
System.Windows.Forms.Tests (83)
System\Resources\ResxDataNodeTests.cs (2)
29
ResXDataNode temp = new("test", converter.
ConvertTo
(bitmap, typeof(byte[])));
43
ResXDataNode temp = new("test", converter.
ConvertTo
(bitmap, typeof(byte[])));
System\Windows\Forms\ColumnHeaderConverterTests.cs (6)
99
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(value, typeof(InstanceDescriptor)));
109
Assert.Throws<ArgumentException>(() => converter.
ConvertTo
(value, typeof(InstanceDescriptor)));
118
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
125
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
132
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
141
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new ColumnHeader(), destinationType));
System\Windows\Forms\CursorConverterTests.cs (16)
80
Assert.Equal("AppStarting", converter.
ConvertTo
(Cursors.AppStarting, typeof(string)));
87
Assert.Throws<FormatException>(() => converter.
ConvertTo
(new Cursor(2), typeof(string)));
96
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
103
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(Cursors.AppStarting, typeof(InstanceDescriptor)));
108
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new Cursor(Cursors.AppStarting.Handle), typeof(InstanceDescriptor)));
115
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new Cursor(2), typeof(InstanceDescriptor)));
122
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(null, typeof(InstanceDescriptor)));
132
Assert.Equal(data, converter.
ConvertTo
(sourceCursor, typeof(byte[])));
142
Assert.Equal(data, converter.
ConvertTo
(sourceCursor, typeof(byte[])));
149
Assert.Throws<FormatException>(() => converter.
ConvertTo
(Cursors.AppStarting, typeof(byte[])));
150
Assert.Throws<InvalidOperationException>(() => converter.
ConvertTo
(new Cursor(Cursors.AppStarting.Handle), typeof(byte[])));
157
Assert.Throws<InvalidOperationException>(() => converter.
ConvertTo
(new Cursor(2), typeof(byte[])));
164
Assert.Empty(Assert.IsType<byte[]>(converter.
ConvertTo
(null, typeof(byte[]))));
171
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
180
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, destinationType));
240
string converted = (string)converter.
ConvertTo
(new Cursor(Cursors.Default.Handle), typeof(string));
System\Windows\Forms\DataGridViewRowConverterTests.cs (1)
29
object descriptor = converter.
ConvertTo
(row, typeof(InstanceDescriptor));
System\Windows\Forms\KeysConverterTests.cs (1)
103
object result = converter.
ConvertTo
(keys, typeof(Enum[]));
System\Windows\Forms\Layout\TableLayoutSettingsTypeConverterTests.cs (12)
167
string result = Assert.IsType<string>(converter.
ConvertTo
(settings, typeof(string)));
190
string result = Assert.IsType<string>(converter.
ConvertTo
(settings, typeof(string)));
208
string result = Assert.IsType<string>(converter.
ConvertTo
(settings, typeof(string)));
217
string result = Assert.IsType<string>(converter.
ConvertTo
(settings, typeof(string)));
231
string result = Assert.IsType<string>(converter.
ConvertTo
(settings, typeof(string)));
244
Assert.Throws<InvalidOperationException>(() => converter.
ConvertTo
(settings, typeof(string)));
253
string result = Assert.IsType<string>(converter.
ConvertTo
(settings, typeof(string)));
265
Assert.Throws<InvalidCastException>(() => converter.
ConvertTo
(settings, typeof(string)));
276
Assert.Throws<InvalidCastException>(() => converter.
ConvertTo
(settings, typeof(string)));
283
Assert.Equal("1", converter.
ConvertTo
(1, typeof(string)));
290
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
301
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(toolStrip.LayoutSettings, destinationType));
System\Windows\Forms\LinkAreaConverterTests.cs (5)
78
Assert.Equal("1, 2", converter.
ConvertTo
(new LinkArea(1, 2), typeof(string)));
87
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(new LinkArea(1, 2), typeof(InstanceDescriptor)));
96
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
103
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
112
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(default(LinkArea), destinationType));
System\Windows\Forms\LinkConverterTests.cs (6)
76
Assert.Equal("1, 2", converter.
ConvertTo
(new LinkLabel.Link(1, 2), typeof(string)));
85
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(new LinkLabel.Link(1, 2), typeof(InstanceDescriptor)));
95
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(new LinkLabel.Link(1, 2, "linkData"), typeof(InstanceDescriptor)));
105
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
112
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
121
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new LinkLabel.Link(), destinationType));
System\Windows\Forms\ListViewGroupConverterTests.cs (5)
205
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(value, typeof(InstanceDescriptor)));
216
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
223
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
230
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
239
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new ListViewGroup(), destinationType));
System\Windows\Forms\ListViewItemConverterTests.cs (5)
260
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(value, typeof(InstanceDescriptor)));
271
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
278
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
285
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
294
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new ListViewItem(), destinationType));
System\Windows\Forms\ListViewSubItemConverterTests.cs (5)
73
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(value, typeof(InstanceDescriptor)));
84
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
91
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
98
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
107
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new ListViewItem.ListViewSubItem(), destinationType));
System\Windows\Forms\OpacityConverterTests.cs (4)
90
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
98
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
105
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
115
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1.1, destinationType));
System\Windows\Forms\PaddingConverterTests.cs (6)
81
Assert.Equal("1, 2, 3, 4", converter.
ConvertTo
(new Padding(1, 2, 3, 4), typeof(string)));
90
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(new Padding(1, 2, 3, 4), typeof(InstanceDescriptor)));
99
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(new Padding(1, 1, 1, 1), typeof(InstanceDescriptor)));
108
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
115
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
124
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(default(Padding), destinationType));
System\Windows\Forms\TableLayoutPanelCellPositionTests.cs (4)
177
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(new TableLayoutPanelCellPosition(1, 2), typeof(InstanceDescriptor)));
187
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
194
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
203
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(default(TableLayoutPanelCellPosition), destinationType));
System\Windows\Forms\TableLayoutStyleTests.cs (5)
141
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(value, typeof(InstanceDescriptor)));
151
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new SubTableLayoutStyle { SizeType = sizeType }, typeof(InstanceDescriptor)));
158
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new object(), null));
165
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
174
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new RowStyle(), destinationType));
System.Xaml.Tests (36)
System\Windows\Markup\StaticExtensionTests.cs (5)
216
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(extension, typeof(InstanceDescriptor)));
226
Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(extension, typeof(InstanceDescriptor)));
227
Assert.Equal(extension.ToString(), converter.
ConvertTo
(extension, typeof(string)));
235
Assert.Throws<ArgumentException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
243
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(extension, typeof(int)));
System\Windows\Markup\TypeExtensionTests.cs (5)
177
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(extension, typeof(InstanceDescriptor)));
187
Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(extension, typeof(InstanceDescriptor)));
188
Assert.Equal(extension.ToString(), converter.
ConvertTo
(extension, typeof(string)));
196
Assert.Throws<ArgumentException>(() => converter.
ConvertTo
(1, typeof(InstanceDescriptor)));
204
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(extension, typeof(int)));
System\Xaml\Replacements\DateTimeConverter2Tests.cs (4)
84
Assert.Equal(date.ToString(format, CultureInfo.InvariantCulture), converter.
ConvertTo
(date, typeof(string)));
94
Assert.Equal(value ?? string.Empty, converter.
ConvertTo
(value, typeof(string)));
104
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(DateTime.MinValue, destinationType));
112
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(DateTime.MinValue, null!));
System\Xaml\Replacements\DateTimeOffsetConverter2Tests.cs (4)
89
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(dateTimeOffset, typeof(InstanceDescriptor)));
103
Assert.Equal(value ?? string.Empty, converter.
ConvertTo
(value, typeof(string)));
112
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(DateTimeOffset.MinValue, destinationType));
120
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(DateTimeOffset.MinValue, null!));
System\Xaml\Replacements\EventConverterTests.cs (3)
165
Assert.Equal(value ?? string.Empty, converter.
ConvertTo
(value, typeof(string)));
175
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(typeof(int), destinationType));
184
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(typeof(int), null!));
System\Xaml\Replacements\TypeListConverterTests.cs (3)
64
Assert.Equal(value ?? string.Empty, converter.
ConvertTo
(value, typeof(string)));
73
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(Array.Empty<Type>(), destinationType));
81
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(Array.Empty<Type>(), null!));
System\Xaml\Replacements\TypeTypeConverterTests.cs (3)
260
Assert.Equal(value ?? string.Empty, converter.
ConvertTo
(value, typeof(string)));
270
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(typeof(int), destinationType));
279
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(typeof(int), null!));
System\Xaml\Replacements\TypeUriConverterTests.cs (6)
114
Assert.Equal("http://google.com", converter.
ConvertTo
(uri, typeof(string)));
132
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(Uri)));
150
InstanceDescriptor descriptor = Assert.IsType<InstanceDescriptor>(converter.
ConvertTo
(value, typeof(InstanceDescriptor)));
163
Assert.Equal(value ?? string.Empty, converter.
ConvertTo
(value, typeof(string)));
171
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(new Uri("http://google.com"), destinationType));
178
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(new Uri("http://google.com"), null!));
System\Xaml\Schema\XamlTypeTypeConverterTests.cs (3)
258
Assert.Equal(value ?? string.Empty, converter.
ConvertTo
(value, typeof(string)));
268
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(type, destinationType));
277
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(type, null!));
WindowsBase.Tests (38)
System\Windows\ExpressionConverterTests.cs (2)
54
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
73
Assert.Throws<NullReferenceException>(() => converter.
ConvertTo
(value, null!));
System\Windows\Input\KeyConverterTests.cs (6)
141
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
154
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, typeof(string)));
167
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, typeof(string)));
179
Assert.Throws<InvalidCastException>(() => converter.
ConvertTo
(value, typeof(string)));
204
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
223
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));
System\Windows\Input\ModifierKeysConverterTests.cs (6)
98
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
116
Assert.Throws<InvalidEnumArgumentException>("value", () => converter.
ConvertTo
(value, typeof(string)));
133
Assert.Throws<NullReferenceException>(() => converter.
ConvertTo
(value, typeof(string)));
145
Assert.Throws<InvalidCastException>(() => converter.
ConvertTo
(value, typeof(string)));
170
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
189
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));
System\Windows\Int32RectConverterTests.cs (4)
30
Assert.Equal(expected, converter.
ConvertTo
(matrix, typeof(string)));
55
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
80
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
99
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));
System\Windows\Media\MatrixConverterTests.cs (4)
30
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
55
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
80
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
99
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));
System\Windows\PointConverterTests.cs (4)
30
Assert.Equal(expected, converter.
ConvertTo
(matrix, typeof(string)));
55
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
80
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
99
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));
System\Windows\RectConverterTests.cs (4)
30
Assert.Equal(expected, converter.
ConvertTo
(matrix, typeof(string)));
55
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
80
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
99
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));
System\Windows\SizeConverterTests.cs (4)
30
Assert.Equal(expected, converter.
ConvertTo
(matrix, typeof(string)));
55
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
80
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
99
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));
System\Windows\VectorConverterTests.cs (4)
30
Assert.Equal(expected, converter.
ConvertTo
(matrix, typeof(string)));
55
Assert.Equal(expected, converter.
ConvertTo
(value, typeof(string)));
80
Assert.Throws<NotSupportedException>(() => converter.
ConvertTo
(value, destinationType));
99
Assert.Throws<ArgumentNullException>("destinationType", () => converter.
ConvertTo
(value, null!));