示例#1
0
文件: Its.cs 项目: holmstrom/Expert
 internal static string GetTestString(Expression<Func<bool>> expr)
 {
     var parser = new Parser();
     return parser.PrettyString(expr);
 }
示例#2
0
 private void TestExpressionParsing(Expression<Func<bool>> expr, string expected)
 {
     Parser parser = new Parser();
     string result = parser.PrettyString(expr);
     Assert.AreEqual(expected, result);
 }
示例#3
0
 public void CorrectStringFor_ConstantExpression()
 {
     Parser parser = new Parser();
     string result = parser.PrettyString(() => true);
     Assert.AreEqual("true", result);
 }
示例#4
0
 public void ProducesNonNullString()
 {
     Parser parser = new Parser();
     string result = parser.PrettyString(() => true);
     Assert.NotNull(result);
 }