@Test
/**
 * tests {@link ScriptUtils#convertToJsValue(String)} for a function value

 */
public void testConvertToJSValue_function() {
    // test for white space
    String jsFunction = "\n function () {alert('1 + 1 ' is 1 + 1);} \n\n";
    assertEquals("function was not converted to js value as expected", jsFunction, ScriptUtils.convertToJsValue(jsFunction));
}