public void Button_Pass() { var cmd = new Cmd.ValidateItem(); InitCommand(cmd); _context.CurrentItem = _itemPassing; cmd.ModeButton = true; var result = cmd.Run(); Assert.That(result.Status, Is.EqualTo(CommandStatus.Success)); }
public void Workflow_Fail_ByID() { var cmd = new Cmd.ValidateItem(); InitCommand(cmd); _context.CurrentItem = _database.GetRootItem(); cmd.ModeGutter = true; cmd.Path = _itemFailing.ID.ToString(); var result = cmd.Run(); Assert.That(result.Status, Is.EqualTo(CommandStatus.Failure)); }
public void All_Fail() { var cmd = new Cmd.ValidateItem(); InitCommand(cmd); _context.CurrentItem = _itemFailing; var result = cmd.Run(); Assert.That(result.Status, Is.EqualTo(CommandStatus.Failure)); }
public void Bar_Pass_ByPath() { var cmd = new Cmd.ValidateItem(); InitCommand(cmd); _context.CurrentItem = _testRoot.Parent; cmd.ModeBar = true; cmd.Path = _testRoot.Name + "/" + _itemPassing.Name; var result = cmd.Run(); Assert.That(result.Status, Is.EqualTo(CommandStatus.Success)); }