diff --git a/src/test/java/com/github/fakemongo/integration/SpringQueryTest.java b/src/test/java/com/github/fakemongo/integration/SpringQueryTest.java old mode 100644 new mode 100755 index 28179c72..04a4045a --- a/src/test/java/com/github/fakemongo/integration/SpringQueryTest.java +++ b/src/test/java/com/github/fakemongo/integration/SpringQueryTest.java @@ -50,6 +50,11 @@ public void should_mixed_data_works_in_spring() throws Exception { assertThat(repository.findLongListWithQuery(10L)).isNotNull(); assertThat(repository.findLongListWithQuery(longList)).hasSize(1); assertThat(repository.findLongListWithQuery(10L)).hasSize(1); + + DomainObject match = repository.findByLongList(10L).get(0); + assertThat(repository.findBy_id(match.get_id())).isNotNull(); + assertThat(repository.findBy_idIgnoreCase(match.get_id())).isNotNull(); + ctx.close(); } @@ -147,4 +152,7 @@ interface QueryRepository extends MongoRepository findByLongList(Long foo); List findByLongList(List foo); + + SpringQueryTest.DomainObject findBy_id(String id); + SpringQueryTest.DomainObject findBy_idIgnoreCase(String id); }