public void AddToSelectionCommandTest() { ICommand addCommand = new AddToSelectionAndHighlightCommand(this.Selection, this.Ribbon); Invoker.ExecuteCommand(addCommand); Assert.IsTrue(this.Selection.GetObjectsOfSelection().Contains(this.Ribbon)); Assert.AreEqual("HighlightSelectionMaterial (Instance)", this.Ribbon.GetComponent <MeshRenderer>().material.name); }
public void RemoveFromSelectionCommandTestRedo() { ICommand addCommand = new AddToSelectionAndHighlightCommand(this.Selection, this.Ribbon); Invoker.ExecuteCommand(addCommand); ICommand removeCommand = new RemoveFromSelectionAndRevertHighlightCommand(this.Selection, this.Ribbon); Invoker.ExecuteCommand(removeCommand); Assert.IsFalse(this.Selection.GetObjectsOfSelection().Contains(this.Ribbon)); Assert.AreNotEqual("HighlightSelectionMaterial (Instance)", this.Ribbon.GetComponent <MeshRenderer>().material.name); }