Exemplo n.º 1
0
        public void Evaluate_TooFewArguments_ThrowsInvalidOperationException()
        {
            var func = new OneArgumentFunction();

            Assert.Throws <InvalidOperationException>(() =>
            {
                func.EvaluateWithData();
            });
        }
Exemplo n.º 2
0
        public void Evaluate_TooManyArguments_ThrowsInvalidOperationException()
        {
            var func = new OneArgumentFunction();

            func.AddArgument(Null.Instance);
            Assert.Throws <FormatException>(() =>
            {
                func.AddArgument(Null.Instance);
            });
            func.EvaluateWithData();
        }