Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 1de287b

Browse filesBrowse files
Adds review changes
1 parent f044fcc commit 1de287b
Copy full SHA for 1de287b

File tree

Expand file treeCollapse file tree

1 file changed

+7
-7
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+7
-7
lines changed
Open diff view settings
Collapse file

‎spring-boot/specification/src/test/java/io/reflectoring/specification/repository/CustomProductRepositoryTest.java‎

Copy file name to clipboardExpand all lines: spring-boot/specification/src/test/java/io/reflectoring/specification/repository/CustomProductRepositoryTest.java
+7-7Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,23 +15,23 @@
1515
class CustomProductRepositoryTest {
1616

1717
@Autowired
18-
private CustomProductRepository productAdapter;
18+
private CustomProductRepository productRepository;
1919

2020
@Test
2121
void getLowRangeProducts() {
22-
List<Product> products = productAdapter.getLowRangeProducts(List.of(Category.MOBILE, Category.TV_APPLIANCES));
22+
List<Product> products = productRepository.getLowRangeProducts(List.of(Category.MOBILE, Category.TV_APPLIANCES));
2323
assertEquals(2, products.size());
2424
}
2525

2626
@Test
2727
void getPremiumProducts() {
28-
List<Product> products = productAdapter.getPremiumProducts(List.of(Category.MEN_FASHION, Category.WOMEN_FASHION));
28+
List<Product> products = productRepository.getPremiumProducts(List.of(Category.MEN_FASHION, Category.WOMEN_FASHION));
2929
assertEquals(2, products.size());
3030
}
3131

3232
@Test
3333
void testGetPremiumProducts() {
34-
List<Product> products = productAdapter.getPremiumProducts("jacket", List.of(Category.MEN_FASHION));
34+
List<Product> products = productRepository.getPremiumProducts("jacket", List.of(Category.MEN_FASHION));
3535
assertEquals(2, products.size());
3636
}
3737

@@ -50,7 +50,7 @@ void testDynamicSpecification() {
5050
List<Filter> filters = new ArrayList<>();
5151
filters.add(nameLike);
5252
filters.add(categories);
53-
List<Product> products = productAdapter.getQueryResult(filters);
53+
List<Product> products = productRepository.getQueryResult(filters);
5454
assertEquals(2, products.size());
5555

5656
Filter lowRange = Filter.builder()
@@ -63,7 +63,7 @@ void testDynamicSpecification() {
6363
filters.add(lowRange);
6464
filters.add(categories);
6565

66-
products = productAdapter.getQueryResult(filters);
66+
products = productRepository.getQueryResult(filters);
6767
assertEquals(2, products.size());
6868

6969
Filter priceEquals = Filter.builder()
@@ -73,7 +73,7 @@ void testDynamicSpecification() {
7373
.build();
7474
filters = new ArrayList<>();
7575
filters.add(priceEquals);
76-
products = productAdapter.getQueryResult(filters);
76+
products = productRepository.getQueryResult(filters);
7777
assertEquals(1, products.size());
7878
}
7979
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.