public void EditComponent_NonComponentWithPages_ThrowsArgumentException(object component) { var editor = new CustomWindowsFormsComponentEditor { GetComponentEditorPagesResult = new Type[] { typeof(int) } }; Assert.Throws <ArgumentException>("component", () => editor.EditComponent(component, null)); Assert.Throws <ArgumentException>("component", () => editor.EditComponent(null, component)); Assert.Throws <ArgumentException>("component", () => editor.EditComponent(null, component, null)); }
public void WindowsFormsComponentEditor_EditComponent_InvokeITypeDescriptorContextObjectIWin32Window_ReturnsFalse(Type[] pages, ITypeDescriptorContext context, object component, IWin32Window owner) { var editor = new CustomWindowsFormsComponentEditor { GetComponentEditorPagesResult = pages }; Assert.False(editor.EditComponent(context, component, owner)); }