public void ShortcutKeysEditor_EditValue_ValidProvider_ReturnsValue(object value)
        {
            var editor              = new ShortcutKeysEditor();
            var mockEditorService   = new Mock <IWindowsFormsEditorService>(MockBehavior.Strict);
            var mockServiceProvider = new Mock <IServiceProvider>(MockBehavior.Strict);

            mockServiceProvider
            .Setup(p => p.GetService(typeof(IWindowsFormsEditorService)))
            .Returns(mockEditorService.Object)
            .Verifiable();
            mockEditorService
            .Setup(e => e.DropDownControl(It.IsAny <Control>()))
            .Verifiable();
            Assert.Equal(value, editor.EditValue(null, mockServiceProvider.Object, value));
            mockServiceProvider.Verify(p => p.GetService(typeof(IWindowsFormsEditorService)), Times.Once());
            mockEditorService.Verify(e => e.DropDownControl(It.IsAny <Control>()), Times.Once());

            // Edit again.
            Assert.Equal(value, editor.EditValue(null, mockServiceProvider.Object, value));
            mockServiceProvider.Verify(p => p.GetService(typeof(IWindowsFormsEditorService)), Times.Exactly(2));
            mockServiceProvider.Verify(p => p.GetService(typeof(IWindowsFormsEditorService)), Times.Exactly(2));
        }
        public void ShortcutKeysEditor_EditValue_InvalidProvider_ReturnsValue(IServiceProvider provider, object value)
        {
            var editor = new ShortcutKeysEditor();

            Assert.Same(value, editor.EditValue(null, provider, value));
        }