コード例 #1
0
        public void TestSelectedChangedWhenItemWhichIsSelected()
        {
            var stage = new Stage();
            var sceneEntity1 = Mock.Of<ISceneEntity>();
            stage.Add(sceneEntity1);
            var sceneEntity2 = Mock.Of<ISceneEntity>();
            stage.Add(sceneEntity2);
            _sceneContent.Stage = stage;
            _sceneContent.SetSelectedItems(new List<ISceneEntity> { sceneEntity1, sceneEntity2 });
            ClearSelectedSceneElementsResult();

            _sceneContent.Stage.Remove(sceneEntity1);

            Assert.IsTrue(_selectedSceneEntitiesEventFired);
            CollectionAssert.DoesNotContain(_sceneContent.SelectedItems, sceneEntity1);
            CollectionAssert.Contains(_sceneContent.SelectedItems, sceneEntity2);
        }
コード例 #2
0
 public void SetUp()
 {
     _stage = new Stage();
 }