Skip to content

Commit

Permalink
ReactiveMemoryDataAccessTest#patchByQuery
Browse files Browse the repository at this point in the history
(cherry picked from commit 7e77091)
  • Loading branch information
f0rb committed Dec 6, 2023
1 parent d8c96fa commit 717569c
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public Mono<Integer> patch(E e) {

@Override
public Mono<Integer> patch(E e, Q q) {
return null;
return Mono.fromSupplier(() -> delegate.patch(e, q));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,4 +72,14 @@ void deleteByQuery() {
.verifyComplete();
}

@Test
void patchByQuery() {
TestEntity testEntity = TestEntity.builder().score(60).build();
TestQuery testQuery = TestQuery.builder().valid(true).build();
testMemoryDataAccess.patch(testEntity, testQuery)
.as(StepVerifier::create)
.expectNextMatches(i -> i == 3)
.verifyComplete();
}

}

0 comments on commit 717569c

Please sign in to comment.