@Test
public void canFactoryProcessViewsShouldBeRobustWithWeirdInput() {

    Dictionary<String, String> headers = new Hashtable<>(2);
    headers.put(BundleScriptingConfigurationConstants.JAHIA_MODULE_SCRIPTING_VIEWS, ",,,");
    assertFalse(ScriptEngineUtils.canFactoryProcessViews(new TestScriptEngineFactory(), headers));
    headers.put(BundleScriptingConfigurationConstants.JAHIA_MODULE_SCRIPTING_VIEWS, ",     foo  \t\n,,");
    assertTrue(ScriptEngineUtils.canFactoryProcessViews(new TestScriptEngineFactory(), headers));
    headers.put(BundleScriptingConfigurationConstants.JAHIA_MODULE_SCRIPTING_VIEWS, ",     js  \t\n,,    bar,");
    assertTrue(ScriptEngineUtils.canFactoryProcessViews(new TestScriptEngineFactory(), headers));
}