AjScript.Commands.Tests.CommandsTests.ExecuteIfCommandWhenFalse C# (CSharp) Метод

ExecuteIfCommandWhenFalse() приватный Метод

private ExecuteIfCommandWhenFalse ( ) : void
Результат void
        public void ExecuteIfCommandWhenFalse()
        {
            IExpression condition = new ConstantExpression(false);
            ICommand setCommand = new SetVariableCommand("a", new ConstantExpression(1));
            IfCommand command = new IfCommand(condition, setCommand);

            Context context = new Context();

            command.Execute(context);

            Assert.AreEqual(Undefined.Instance, context.GetValue("a"));
        }