Execute() 공개 메소드

public Execute ( IEnumerable arguments, ParsingContext context ) : CompileResult
arguments IEnumerable
context ParsingContext
리턴 ExcelFormulaParser.Engine.ExpressionGraph.CompileResult
 public void DateFunctionShouldReturnADate()
 {
     var func = new Date();
     var args = FunctionsHelper.CreateArgs(2012, 4, 3);
     var result = func.Execute(args, _parsingContext);
     Assert.AreEqual(DataType.Date, result.DataType);
 }
 public void DateFunctionShouldReturnACorrectDate()
 {
     var expectedDate = new DateTime(2012, 4, 3);
     var func = new Date();
     var args = FunctionsHelper.CreateArgs(2012, 4, 3);
     var result = func.Execute(args, _parsingContext);
     Assert.AreEqual(expectedDate.ToOADate(), result.Result);
 }
 public void DateFunctionShouldMonthFromPrevYearIfMonthIsNegative()
 {
     var expectedDate = new DateTime(2011, 11, 3);
     var func = new Date();
     var args = FunctionsHelper.CreateArgs(2012, -1, 3);
     var result = func.Execute(args, _parsingContext);
     Assert.AreEqual(expectedDate.ToOADate(), result.Result);
 }