Exemplo n.º 1
0
 public CommandExecutor(ICommandParser parser, ICommandExecutorOptions executorOptions, IAttributeDecorator attributeDecorator, IValueConverter valueConverter, ICommandHelper commandHelper, ITypeHelper typeHelper, ICommandExecutorImpl impl = null)
 {
     _parser             = parser;
     _options            = executorOptions;
     _attributeDecorator = attributeDecorator;
     _valueConverter     = valueConverter;
     _commandHelper      = commandHelper;
     _typeHelper         = typeHelper;
     _impl = impl ?? this;
 }
 public CommandExecutor CreateSut(ICommandParser parser = null, ICommandExecutorOptions executorOptions = null, IAttributeDecorator attributeDecorator = null, IValueConverter valueConverter = null, ICommandHelper commandHelper = null, ITypeHelper typeHelper = null, ICommandExecutorImpl impl = null)
 {
     return(new CommandExecutor(parser ?? Substitute.For <ICommandParser>(),
                                executorOptions ?? Substitute.For <ICommandExecutorOptions>(),
                                attributeDecorator ?? Substitute.For <IAttributeDecorator>(),
                                valueConverter ?? Substitute.For <IValueConverter>(),
                                commandHelper ?? Substitute.For <ICommandHelper>(),
                                typeHelper ?? Substitute.For <ITypeHelper>(),
                                impl));
 }