protected override CommandBase TestCommand(IVBE vbe, RubberduckParserState state, IRewritingManager rewritingManager, ISelectionService selectionService)
        {
            var msgBox      = new Mock <IMessageBox>().Object;
            var refactoring = new ImplementInterfaceRefactoring(state, rewritingManager, selectionService);
            var notifier    = new ImplementInterfaceFailedNotifier(msgBox);

            return(new RefactorImplementInterfaceCommand(refactoring, notifier, state, selectionService));
        }
示例#2
0
        public RefactorImplementInterfaceCommand(
            ImplementInterfaceRefactoring refactoring,
            ImplementInterfaceFailedNotifier implementInterfaceFailedNotifier,
            RubberduckParserState state,
            ISelectionProvider selectionProvider)
            : base(refactoring, implementInterfaceFailedNotifier, selectionProvider, state)
        {
            _state = state;

            AddToCanExecuteEvaluation(SpecializedEvaluateCanExecute);
        }