fixed failing searchControllerTests
This commit is contained in:
@@ -63,7 +63,7 @@ public class HomeboxSearchProvider implements SearchProvider {
|
||||
String id = i.id();
|
||||
String title = i.name();
|
||||
String description = i.description();
|
||||
Map<String, Object> extraSearchResponseData = Map.of("extraData", i.parent());
|
||||
Map<String, Object> extraSearchResponseData = Map.of("parent", i.parent());
|
||||
return new ServiceItem(id, title, description, extraSearchResponseData);
|
||||
}).toList();
|
||||
|
||||
|
||||
@@ -93,8 +93,7 @@ class SearchControllerTest {
|
||||
.andExpect(status().isOk())
|
||||
.andExpect(jsonPath("$.content[0].title").value("MacBook Pro A1398"))
|
||||
.andExpect(jsonPath("$.totalElements").value(1))
|
||||
.andExpect(jsonPath("$.content[0].extraData.location.name")
|
||||
.value("Server Schrank Ikea weiß"));
|
||||
.andExpect(jsonPath("$.content[0].extraData.parent.name").value("Server Schrank Ikea weiß"));
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user