38 references to ContainsText
System.Windows.Forms (1)
System\Windows\Forms\OLE\DataObject.cs (1)
313
public virtual bool ContainsText() =>
ContainsText
(TextDataFormat.UnicodeText);
System.Windows.Forms.Tests (37)
System\Windows\Forms\DataObjectTests.ClipboardTests.cs (10)
124
dataObject.
ContainsText
(TextDataFormat.Text).Should().Be(format == DataFormats.UnicodeText);
125
dataObject.
ContainsText
(TextDataFormat.UnicodeText).Should().Be(format == DataFormats.UnicodeText);
126
dataObject.
ContainsText
(TextDataFormat.Rtf).Should().Be(format == DataFormats.Rtf);
127
dataObject.
ContainsText
(TextDataFormat.Html).Should().Be(format == DataFormats.Html);
128
dataObject.
ContainsText
(TextDataFormat.CommaSeparatedValue).Should().Be(format == DataFormats.CommaSeparatedValue);
184
dataObject.
ContainsText
(TextDataFormat.Text).Should().Be(format == DataFormats.UnicodeText);
185
dataObject.
ContainsText
(TextDataFormat.UnicodeText).Should().Be(format == DataFormats.UnicodeText);
186
dataObject.
ContainsText
(TextDataFormat.Rtf).Should().Be(format == DataFormats.Rtf);
187
dataObject.
ContainsText
(TextDataFormat.Html).Should().Be(format == DataFormats.Html);
188
dataObject.
ContainsText
(TextDataFormat.CommaSeparatedValue).Should().Be(format == DataFormats.CommaSeparatedValue);
System\Windows\Forms\DataObjectTests.cs (27)
149
.Setup(o => o.
ContainsText
(TextDataFormat.UnicodeText))
153
mockDataObject.Verify(o => o.
ContainsText
(TextDataFormat.UnicodeText), Times.Once());
161
dataObject.
ContainsText
(format).Should().BeFalse();
185
.Setup(o => o.
ContainsText
(format))
191
mockDataObject.Object.
ContainsText
(format).Should().Be(result);
200
((Action)(() => dataObject.
ContainsText
(format))).Should().Throw<InvalidEnumArgumentException>().WithParameterName("format");
1205
dataObject.
ContainsText
(TextDataFormat.Text).Should().Be(format == DataFormats.UnicodeText);
1206
dataObject.
ContainsText
(TextDataFormat.UnicodeText).Should().Be(format == DataFormats.UnicodeText);
1207
dataObject.
ContainsText
(TextDataFormat.Rtf).Should().Be(format == DataFormats.Rtf);
1208
dataObject.
ContainsText
(TextDataFormat.Html).Should().Be(format == DataFormats.Html);
1209
dataObject.
ContainsText
(TextDataFormat.CommaSeparatedValue).Should().Be(format == DataFormats.CommaSeparatedValue);
1245
dataObject.
ContainsText
(TextDataFormat.Text).Should().BeFalse();
1246
dataObject.
ContainsText
(TextDataFormat.UnicodeText).Should().BeFalse();
1247
dataObject.
ContainsText
(TextDataFormat.Rtf).Should().BeFalse();
1248
dataObject.
ContainsText
(TextDataFormat.Html).Should().BeFalse();
1249
dataObject.
ContainsText
(TextDataFormat.CommaSeparatedValue).Should().BeFalse();
1354
dataObject.
ContainsText
(TextDataFormat.Text).Should().Be(format == DataFormats.UnicodeText);
1355
dataObject.
ContainsText
(TextDataFormat.UnicodeText).Should().Be(format == DataFormats.UnicodeText);
1356
dataObject.
ContainsText
(TextDataFormat.Rtf).Should().Be(format == DataFormats.Rtf);
1357
dataObject.
ContainsText
(TextDataFormat.Html).Should().Be(format == DataFormats.Html);
1358
dataObject.
ContainsText
(TextDataFormat.CommaSeparatedValue).Should().Be(format == DataFormats.CommaSeparatedValue);
1398
dataObject.
ContainsText
(TextDataFormat.Text).Should().BeFalse();
1399
dataObject.
ContainsText
(TextDataFormat.UnicodeText).Should().BeFalse();
1400
dataObject.
ContainsText
(TextDataFormat.Rtf).Should().BeFalse();
1401
dataObject.
ContainsText
(TextDataFormat.Html).Should().BeFalse();
1402
dataObject.
ContainsText
(TextDataFormat.CommaSeparatedValue).Should().BeFalse();
1754
dataObject.
ContainsText
(format).Should().BeTrue();