@Test public void testEvaluate3() { Literal pattern = f.createLiteral("FooBar"); Literal startIndex = f.createLiteral(4); try { ucaseFunc.evaluate(f, pattern, startIndex); fail("illegal number of parameters"); } catch (ValueExprEvaluationException e) { // do nothing, expected } }
@Test public void testEvaluate2() { Literal pattern = f.createLiteral("FooBar"); try { Literal result = ucaseFunc.evaluate(f, pattern); assertTrue(result.getLabel().equals("FOOBAR")); } catch (ValueExprEvaluationException e) { fail(e.getMessage()); } }
@Override public XStream<String> uppercase() { return new XStreamImpl<>(UpperCase.uppercase().apply(new Stringify<T>().apply(stream))); }