Skip to content

Commit

Permalink
Polishing.
Browse files Browse the repository at this point in the history
Removed Given/When/Then comments.
They are of limited use, especially since it is debatable what belongs in which section.

See spring-projects#2176
Original pull request spring-projects#2401
  • Loading branch information
schauder authored and AntonMolganov committed Apr 14, 2022
1 parent ea5b214 commit 7cbfad9
Showing 1 changed file with 0 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,14 @@ public class QueryByExampleWithOptionalEmptyTests {
@Test
void queryByExampleTreatsEmptyOptionalsLikeNulls() {

// given
UserWithOptionalField user = new UserWithOptionalField();
user.setName("Greg");
repository.saveAndFlush(user);

// when
UserWithOptionalField probe = new UserWithOptionalField();
probe.setName("Greg");
Example<UserWithOptionalField> example = Example.of(probe);

// then
List<UserWithOptionalField> results = repository.findAll(example);

assertThat(results).hasSize(1);
Expand Down

0 comments on commit 7cbfad9

Please sign in to comment.