Added tests for thymeleaf/thymeleaf#305