MCPcopy Create free account
hub / github.com/apache/tomcat / testGetType03

Method testGetType03

test/jakarta/el/TestMapELResolver.java:48–57  ·  view source on GitHub ↗

Tests that a valid property is resolved.

()

Source from the content-addressed store, hash-verified

46 * Tests that a valid property is resolved.
47 */
48 @Test
49 public void testGetType03() {
50 MapELResolver mapELResolver = new MapELResolver();
51 ELContext context = new StandardELContext(ELManager.getExpressionFactory());
52
53 Class<?> result = mapELResolver.getType(context, new HashMap<>(), "test");
54
55 Assert.assertEquals(Object.class, result);
56 Assert.assertTrue(context.isPropertyResolved());
57 }
58
59 /**
60 * Tests that a null context results in an NPE as per EL Javadoc.

Callers

nothing calls this directly

Calls 3

getExpressionFactoryMethod · 0.95
getTypeMethod · 0.95
isPropertyResolvedMethod · 0.45

Tested by

no test coverage detected