@Test
public void testSetFallbackNotAllowed() {

    Logger logger = Logger.getLogger(EnvFunction.class.getName());
    Formatter formatter = new SimpleFormatter();
    ByteArrayOutputStream out = new ByteArrayOutputStream();
    Handler handler = new StreamHandler(out, formatter);
    logger.addHandler(handler);
    try {
        EnvFunction function = new EnvFunction();
        function.setFallbackValue(ff.literal(0));
        handler.flush();
        String logMsg = out.toString();
        assertNotNull(logMsg);
        assertTrue(logMsg.toLowerCase().contains("setfallbackvalue"));
    } finally {
        logger.removeHandler(handler);
    }
}