public void TestInitialize() { ScreenFactory = Substitute.For <IScreenFactory>(); WindowManager = Substitute.For <IWindowManagerEx>(); QueueExplorer = Substitute.For <IQueueExplorerViewModel>(); EndpointExplorer = Substitute.For <IEndpointExplorerViewModel>(); MessageList = Substitute.For <IMessageListViewModel>(); StatusbarManager = Substitute.For <IStatusBarManager>(); EventAggregator = Substitute.For <IEventAggregator>(); MessageFlow = Substitute.For <IMessageFlowViewModel>(); SagaWindow = Substitute.For <ISagaWindowViewModel>(); MessageBodyView = Substitute.For <IMessageBodyViewModel>(); MessageProperties = Substitute.For <IMessagePropertiesViewModel>(); View = Substitute.For <IShellViewStub>(); HeaderView = Substitute.For <IMessageHeadersViewModel>(); SettingsProvider = Substitute.For <ISettingsProvider>(); LicenseManager = Substitute.For <AppLicenseManager>(); LogWindow = Substitute.For <ILogWindowViewModel>(); ConnectToViewModel = Substitute.For <IConnectToMachineViewModel>(); SettingsProvider.GetSettings <ProfilerSettings>().Returns(DefaultAppSetting()); App = Substitute.For <IAppCommands>(); CommandLineArgParser = MockEmptyStartupOptions(); shell = new ShellViewModel(App, ScreenFactory, WindowManager, QueueExplorer, EndpointExplorer, MessageList, StatusbarManager, EventAggregator, LicenseManager, MessageFlow, SagaWindow, MessageBodyView, HeaderView, SettingsProvider, MessageProperties, LogWindow, CommandLineArgParser); ScreenFactory.CreateScreen <IConnectToMachineViewModel>().Returns(ConnectToViewModel); shell.AttachView(View, null); }
public const int AutoRefreshInterval = 15000; //TODO: Wire to configuration/settings public ShellViewModel( IScreenFactory screenFactory, IWindowManagerEx windowManager, IExplorerViewModel explorer, IMessageListViewModel messages, IStatusBarManager statusBarManager, IEventAggregator eventAggregator, IConversationViewModel conversation, IMessageBodyViewModel messageBodyViewer, IEnumerable <IHeaderInfoViewModel> headers) { _screenFactory = screenFactory; _windowManager = windowManager; _eventAggregator = eventAggregator; Headers = headers; Conversation = conversation; StatusBarManager = statusBarManager; Explorer = explorer; MessageBody = messageBodyViewer; Messages = messages; Items.Add(messageBodyViewer); Items.Add(conversation); Items.Add(explorer); Items.Add(messages); InitializeAutoRefreshTimer(); }
public void TestInitialize() { ScreenFactory = Substitute.For <IScreenFactory>(); WindowManager = Substitute.For <IWindowManagerEx>(); QueueExplorer = Substitute.For <IQueueExplorerViewModel>(); EndpointExplorer = Substitute.For <IEndpointExplorerViewModel>(); MessageList = Substitute.For <IMessageListViewModel>(); NetworkOperations = Substitute.For <INetworkOperations>(); ExceptionHandler = Substitute.For <IExceptionHandler>(); StatusbarManager = Substitute.For <StatusBarManager>(); EventAggregator = Substitute.For <IEventAggregator>(); MessageFlow = Substitute.For <IMessageFlowViewModel>(); MessageBodyView = Substitute.For <IMessageBodyViewModel>(); MessageProperties = Substitute.For <IMessagePropertiesViewModel>(); View = Substitute.For <IShellViewStub>(); SettingsProvider = Substitute.For <ISettingsProvider>(); LicenseManager = Substitute.For <ILicenseManager>(); LogWindow = Substitute.For <ILogWindowViewModel>(); ConnectToViewModel = Substitute.For <ConnectToMachineViewModel>(NetworkOperations); SettingsProvider.GetSettings <ProfilerSettings>().Returns(DefaultAppSetting()); App = Substitute.For <IAppCommands>(); shell = new ShellViewModel(App, ScreenFactory, WindowManager, QueueExplorer, EndpointExplorer, MessageList, StatusbarManager, EventAggregator, LicenseManager, MessageFlow, MessageBodyView, SettingsProvider, MessageProperties, LogWindow); ScreenFactory.CreateScreen <ConnectToMachineViewModel>().Returns(ConnectToViewModel); shell.AttachView(View, null); }
public ShellViewModel( IAppCommands appCommander, IScreenFactory screenFactory, IWindowManagerEx windowManager, IQueueExplorerViewModel queueExplorer, IEndpointExplorerViewModel endpointExplorer, IMessageListViewModel messages, IStatusBarManager statusBarManager, IEventAggregator eventAggregator, AppLicenseManager licenseManager, IMessageFlowViewModel messageFlow, ISagaWindowViewModel sagaWindow, IMessageBodyViewModel messageBodyViewer, IMessageHeadersViewModel messageHeadersViewer, ISettingsProvider settingsProvider, IMessagePropertiesViewModel messageProperties, ILogWindowViewModel logWindow, ICommandLineArgParser comandLineArgParser) { _appCommander = appCommander; _screenFactory = screenFactory; _windowManager = windowManager; _eventAggregator = eventAggregator; _licenseManager = licenseManager; _settingsProvider = settingsProvider; _comandLineArgParser = comandLineArgParser; MessageProperties = messageProperties; MessageFlow = messageFlow; SagaWindow = sagaWindow; StatusBarManager = statusBarManager; QueueExplorer = queueExplorer; EndpointExplorer = endpointExplorer; MessageHeaders = messageHeadersViewer; MessageBody = messageBodyViewer; Messages = messages; LogWindow = logWindow; Items.Add(queueExplorer); Items.Add(endpointExplorer); Items.Add(messages); Items.Add(messageHeadersViewer); Items.Add(messageBodyViewer); Items.Add(messageFlow); InitializeAutoRefreshTimer(); InitializeIdleTimer(); }
public void TestInitialize() { ScreenFactory = Substitute.For<IScreenFactory>(); WindowManager = Substitute.For<IWindowManagerEx>(); QueueExplorer = Substitute.For<IQueueExplorerViewModel>(); EndpointExplorer = Substitute.For<IEndpointExplorerViewModel>(); MessageList = Substitute.For<IMessageListViewModel>(); NetworkOperations = Substitute.For<INetworkOperations>(); ExceptionHandler = Substitute.For<IExceptionHandler>(); StatusbarManager = Substitute.For<StatusBarManager>(); EventAggregator = Substitute.For<IEventAggregator>(); MessageFlow = Substitute.For<IMessageFlowViewModel>(); MessageBodyView = Substitute.For<IMessageBodyViewModel>(); MessageProperties = Substitute.For<IMessagePropertiesViewModel>(); View = Substitute.For<IShellViewStub>(); SettingsProvider = Substitute.For<ISettingsProvider>(); LicenseManager = Substitute.For<ILicenseManager>(); LogWindow = Substitute.For<ILogWindowViewModel>(); ConnectToViewModel = Substitute.For<ConnectToMachineViewModel>(NetworkOperations); SettingsProvider.GetSettings<ProfilerSettings>().Returns(DefaultAppSetting()); App = Substitute.For<IAppCommands>(); shell = new ShellViewModel(App, ScreenFactory, WindowManager, QueueExplorer, EndpointExplorer, MessageList, StatusbarManager, EventAggregator, LicenseManager, MessageFlow, MessageBodyView, SettingsProvider, MessageProperties, LogWindow); ScreenFactory.CreateScreen<ConnectToMachineViewModel>().Returns(ConnectToViewModel); shell.AttachView(View, null); }
public void TestInitialize() { ScreenFactory = Substitute.For<IScreenFactory>(); WindowManager = Substitute.For<IWindowManagerEx>(); QueueExplorer = Substitute.For<IQueueExplorerViewModel>(); EndpointExplorer = Substitute.For<IEndpointExplorerViewModel>(); MessageList = Substitute.For<IMessageListViewModel>(); StatusbarManager = Substitute.For<IStatusBarManager>(); EventAggregator = Substitute.For<IEventAggregator>(); MessageFlow = Substitute.For<IMessageFlowViewModel>(); SagaWindow = Substitute.For<ISagaWindowViewModel>(); MessageBodyView = Substitute.For<IMessageBodyViewModel>(); MessageProperties = Substitute.For<IMessagePropertiesViewModel>(); View = Substitute.For<IShellViewStub>(); HeaderView = Substitute.For<IMessageHeadersViewModel>(); SettingsProvider = Substitute.For<ISettingsProvider>(); LicenseManager = Substitute.For<AppLicenseManager>(); LogWindow = Substitute.For<ILogWindowViewModel>(); ConnectToViewModel = Substitute.For<IConnectToMachineViewModel>(); SettingsProvider.GetSettings<ProfilerSettings>().Returns(DefaultAppSetting()); App = Substitute.For<IAppCommands>(); CommandLineArgParser = MockEmptyStartupOptions(); shell = new ShellViewModel(App, ScreenFactory, WindowManager, QueueExplorer, EndpointExplorer, MessageList, StatusbarManager, EventAggregator, LicenseManager, MessageFlow, SagaWindow, MessageBodyView, HeaderView, SettingsProvider, MessageProperties, LogWindow, CommandLineArgParser); ScreenFactory.CreateScreen<IConnectToMachineViewModel>().Returns(ConnectToViewModel); shell.AttachView(View, null); }