Exemplo n.º 1
0
        public void AddShortcuts_WhenCalled_FillsCommands()
        {
            //Arrange
            var vm = new MainViewModel { EventAggregator = CreateEventAggregator() };
            var cmd1 = Mock.Create<ITitledCommand>();
            var cmd2 = Mock.Create<ITitledCommand>();
            var cmd3 = Mock.Create<ITitledCommand>();

            //Act
            vm.AddShortcuts(new List<ITitledCommand>{cmd1, cmd2, cmd3});

            //Assert
            Assert.AreEqual(3, vm.Commands.Count);
        }