Skip to content

Commit d9a18d9

Browse files
authored
fix (#447)
1 parent 3e90d3e commit d9a18d9

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

test/System.Linq.Dynamic.Core.Tests/DynamicExpressionParserTests.cs

+9-9
Original file line numberDiff line numberDiff line change
@@ -1122,10 +1122,10 @@ public void DynamicExpressionParser_ParseLambda_NullPropagation_InstanceMethod_Z
11221122
var lambdaExpression = DynamicExpressionParser.ParseLambda(typeof(Foo), null, expression, new Foo());
11231123

11241124
// Assert
1125-
#if NET452
1126-
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.Zero() != null)), Convert(Param_0.FooValue.Zero().Length), null)");
1127-
#else
1125+
#if NETCOREAPP3_1
11281126
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.Zero() != null)), Convert(Param_0.FooValue.Zero().Length, Nullable`1), null)");
1127+
#else
1128+
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.Zero() != null)), Convert(Param_0.FooValue.Zero().Length), null)");
11291129
#endif
11301130
}
11311131

@@ -1139,10 +1139,10 @@ public void DynamicExpressionParser_ParseLambda_NullPropagation_InstanceMethod_O
11391139
var lambdaExpression = DynamicExpressionParser.ParseLambda(typeof(Foo), null, expression, new Foo());
11401140

11411141
// Assert
1142-
#if NET452
1143-
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.One(1) != null)), Convert(Param_0.FooValue.One(1).Length), null)");
1144-
#else
1142+
#if NETCOREAPP3_1
11451143
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.One(1) != null)), Convert(Param_0.FooValue.One(1).Length, Nullable`1), null)");
1144+
#else
1145+
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.One(1) != null)), Convert(Param_0.FooValue.One(1).Length), null)");
11461146
#endif
11471147
}
11481148

@@ -1156,10 +1156,10 @@ public void DynamicExpressionParser_ParseLambda_NullPropagation_InstanceMethod_T
11561156
var lambdaExpression = DynamicExpressionParser.ParseLambda(typeof(Foo), null, expression, new Foo());
11571157

11581158
// Assert
1159-
#if NET452
1160-
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.Two(1, 42) != null)), Convert(Param_0.FooValue.Two(1, 42).Length), null)");
1161-
#else
1159+
#if NETCOREAPP3_1
11621160
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.Two(1, 42) != null)), Convert(Param_0.FooValue.Two(1, 42).Length, Nullable`1), null)");
1161+
#else
1162+
lambdaExpression.ToString().Should().Be("Param_0 => IIF((((Param_0 != null) AndAlso (Param_0.FooValue != null)) AndAlso (Param_0.FooValue.Two(1, 42) != null)), Convert(Param_0.FooValue.Two(1, 42).Length), null)");
11631163
#endif
11641164
}
11651165

0 commit comments

Comments
 (0)