77
88import java .net .URI ;
99
10- import org .junit .jupiter .api .Disabled ;
1110import org .junit .jupiter .api .Test ;
1211import org .springframework .beans .factory .annotation .Autowired ;
1312import org .springframework .boot .test .autoconfigure .web .servlet .AutoConfigureMockMvc ;
@@ -197,12 +196,11 @@ void testFilterNotExpanded() throws Exception {
197196 .andExpect (jsonPath ("$.value[1]" ).doesNotExist ());
198197 }
199198
200- @ Disabled
201199 @ Test
202200 @ WithMockUser (username = "admin" )
203201 void testFilterExpandLevels () throws Exception {
204202 String expandLevelsJson = """
205- [{"NodeID":10 ,"Levels":1},{"NodeID":20 ,"Levels":1}]\
203+ [{"NodeID":100 ,"Levels":1},{"NodeID":200 ,"Levels":1}]\
206204 """ ;
207205 String unencoded = genresURI + "?$select=DistanceFromRoot,DrillState,ID,LimitedDescendantCount,name"
208206 + "&$apply=ancestors($root/GenreHierarchy,GenreHierarchy,ID,filter(name eq 'Autobiography'),keep start)/orderby(name)"
@@ -212,7 +210,7 @@ void testFilterExpandLevels() throws Exception {
212210 URI uri = URI .create (uriString );
213211 client .perform (get (uri ))
214212 .andExpect (status ().isOk ())
215- .andExpect (jsonPath ("$.value[0].ID" ).value (20 ))
213+ .andExpect (jsonPath ("$.value[0].ID" ).value (200 ))
216214 .andExpect (jsonPath ("$.value[0].name" ).value ("Non-Fiction" ))
217215 .andExpect (jsonPath ("$.value[0].DrillState" ).value ("expanded" ))
218216 .andExpect (jsonPath ("$.value[0].DistanceFromRoot" ).value (0 ))
0 commit comments