SWF-1136 Make Spring EL the default expression language used. The current implementation is functionally equivalent except it ignores the configured Web Flow ConversionService and uses the Spring 3 conversion system instead.

This commit is contained in:
Rossen Stoyanchev
2010-04-27 14:45:39 +00:00
parent afa33607e2
commit 7372b31184
45 changed files with 1113 additions and 352 deletions

View File

@@ -101,7 +101,7 @@ public class ELExpressionParserCompatibilityTests extends TestCase {
public void testParseEvalExpressionWithContextCustomELVariableResolver() {
String expressionString = "specialProperty";
Expression exp = parser.parseExpression(expressionString, new FluentParserContext().evaluate(TestBean.class));
assertEquals("Custom resolver resolved this special property!", exp.getValue(new TestBean()));
assertEquals("Custom resolver resolved this special property!", exp.getValue(null));
}
public void testParseBeanEvalExpressionInvalidELVariable() {

View File

@@ -7,14 +7,14 @@ import java.util.Map;
import junit.framework.TestCase;
import org.springframework.binding.expression.ExpressionParser;
import org.springframework.binding.expression.el.DefaultExpressionFactoryUtils;
import org.springframework.binding.expression.el.ELExpressionParser;
import org.springframework.binding.expression.spel.SpringELExpressionParser;
import org.springframework.binding.mapping.impl.DefaultMapper;
import org.springframework.binding.mapping.impl.DefaultMapping;
import org.springframework.expression.spel.standard.SpelExpressionParser;
public class DefaultMapperTests extends TestCase {
private DefaultMapper mapper = new DefaultMapper();
private ExpressionParser parser = new ELExpressionParser(DefaultExpressionFactoryUtils.createExpressionFactory());
private ExpressionParser parser = new SpringELExpressionParser(new SpelExpressionParser());
public void testMapping() {
DefaultMapping mapping1 = new DefaultMapping(parser.parseExpression("foo", null), parser.parseExpression("bar",