Skip to content

Commit

Permalink
add log
Browse files Browse the repository at this point in the history
  • Loading branch information
stormning committed Jun 18, 2016
1 parent 33e42b7 commit 11ee9ad
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ public String process(String entityName, String methodName, Map<String, Object>
cfg.getTemplate(getTemplateKey(entityName, methodName), encoding).process(model, writer);
return writer.toString();
} catch (Exception e) {
logger.error("process template error. Entity name: " + entityName + " methodName:" + methodName, e);
return StringUtils.EMPTY;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/test/java/com/slyak/spring/jpa/JpaTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public void findByTemplateQueryAndReturnDTOs() {
public void findByTemplateQueryWithTemplateQueryObject() {
SampleQuery sq = new SampleQuery();
sq.setContent("world");
List<Sample> samples = sampleRepository.findByTemplateQueryObject(sq);
List<Sample> samples = sampleRepository.findByTemplateQueryObject(sq,null);
Assert.assertTrue(samples.size() == 10);
}
}

0 comments on commit 11ee9ad

Please sign in to comment.