public static VelocityEngine getEngine() {

        try {
            val props = new Properties();
            props.setProperty(RuntimeConstants.INPUT_ENCODING, "UTF-8");
            props.setProperty(RuntimeConstants.RESOURCE_LOADER, "classpath");
            props.setProperty("resource.loader.string.class", StringResourceLoader.class.getName());
            props.setProperty("resource.loader.classpath.class", ClasspathResourceLoader.class.getName());
            props.setProperty(RuntimeConstants.RESOURCE_LOADERS, "classpath,string");
            val engine = new VelocityEngine();
            engine.init(props);
            return engine;
        } catch (final Exception e) {
            throw new TechnicalException("Error configuring velocity", e);
        }

    }
@Test
    public void defaultProperties()  {
        val engine = VelocityEngineFactory.getEngine();
        assertNotNull(engine);
        assertEquals("org.apache.velocity.runtime.resource.loader.StringResourceLoader",
            engine.getProperty("resource.loader.string.class"));
        assertEquals("org.apache.velocity.runtime.resource.loader.ClasspathResourceLoader",
            engine.getProperty("resource.loader.classpath.class"));
        assertEquals(vector("classpath"), engine.getProperty("resource.loaders"));
        assertEquals("UTF-8", engine.getProperty(RuntimeConstants.INPUT_ENCODING));
    }