From 436882ddd93309a8eeca8255b5a511b841813cbc Mon Sep 17 00:00:00 2001 From: Khanh Nguyen Date: Thu, 18 Jul 2024 16:22:15 +0700 Subject: [PATCH] Fix sonar issues --- .../com/axonivy/market/service/FeedbackServiceImplTest.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/marketplace-service/src/test/java/com/axonivy/market/service/FeedbackServiceImplTest.java b/marketplace-service/src/test/java/com/axonivy/market/service/FeedbackServiceImplTest.java index 9508091ea..77b7f14e3 100644 --- a/marketplace-service/src/test/java/com/axonivy/market/service/FeedbackServiceImplTest.java +++ b/marketplace-service/src/test/java/com/axonivy/market/service/FeedbackServiceImplTest.java @@ -51,7 +51,9 @@ void testFindFeedbacks_ProductNotFound() { when(productRepository.findById(productId)).thenReturn(Optional.empty()); - assertThrows(NotFoundException.class, () -> feedbackService.findFeedbacks(productId, Pageable.unpaged())); + Pageable unpaged = Pageable.unpaged(); + + assertThrows(NotFoundException.class, () -> feedbackService.findFeedbacks(productId, unpaged)); verify(productRepository, times(1)).findById(productId); verify(feedbackRepository, never()).searchByProductId(any(), any());