MCPcopy Index your code
hub / github.com/apache/tomcat / testSetValue05

Method testSetValue05

test/jakarta/el/TestArrayELResolver.java:278–285  ·  view source on GitHub ↗

Tests a coercion cannot be performed as the key is not integer.

()

Source from the content-addressed store, hash-verified

276 * Tests a coercion cannot be performed as the key is not integer.
277 */
278 @Test(expected = IllegalArgumentException.class)
279 public void testSetValue05() {
280 ArrayELResolver resolver = new ArrayELResolver();
281 ELContext context = new StandardELContext(ELManager.getExpressionFactory());
282
283 String[] base = new String[] { "element" };
284 resolver.setValue(context, base, "key", "new-element");
285 }
286
287 /**
288 * Tests that the key is out of bounds and exception will be thrown.

Callers

nothing calls this directly

Calls 2

getExpressionFactoryMethod · 0.95
setValueMethod · 0.95

Tested by

no test coverage detected