Exemplo n.º 1
0
 // ReSharper disable SuggestBaseTypeForParameter
 public CommandContainer(
     FullscreenCommand fullScreenCommand,
     RefreshCommand refreshCommand,
     ShowSettingsCommand showSettingsCommand)
 {
     _fullscreenCommand   = fullScreenCommand;
     _refreshCommand      = refreshCommand;
     _showSettingsCommand = showSettingsCommand;
 }
Exemplo n.º 2
0
        // ReSharper disable SuggestBaseTypeForParameter
        public CommandContainer(
			FullscreenCommand fullScreenCommand, 
			RefreshCommand refreshCommand, 
			ShowSettingsCommand showSettingsCommand)
        {
            _fullscreenCommand = fullScreenCommand;
            _refreshCommand = refreshCommand;
            _showSettingsCommand = showSettingsCommand;
        }
Exemplo n.º 3
0
        public void CanShowSettingsCommand()
        {
            var settingsWindow = MockRepository.GenerateMock<ISettingsWindow>();

            var command = new ShowSettingsCommand(_view, settingsWindow);
            command.Execute(null);

            command.CanExecute(null).ShouldBe(true);
            settingsWindow.ShouldHaveBeenCalled(s => s.ShowDialog());
        }