|
|
@ -84,8 +84,9 @@ public class InternalResourceViewTests { |
|
|
|
view.render(model, request, response); |
|
|
|
view.render(model, request, response); |
|
|
|
assertEquals(url, response.getForwardedUrl()); |
|
|
|
assertEquals(url, response.getForwardedUrl()); |
|
|
|
|
|
|
|
|
|
|
|
model.keySet().stream().forEach( |
|
|
|
|
|
|
|
key -> assertEquals("Values for model key '" + key + "' must match", model.get(key), request.getAttribute(key)) |
|
|
|
model.forEach( |
|
|
|
|
|
|
|
(key, value) -> assertEquals("Values for model key '" + key + "' must match", value, request.getAttribute(key)) |
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -101,7 +102,7 @@ public class InternalResourceViewTests { |
|
|
|
view.render(model, request, response); |
|
|
|
view.render(model, request, response); |
|
|
|
assertEquals(url, response.getIncludedUrl()); |
|
|
|
assertEquals(url, response.getIncludedUrl()); |
|
|
|
|
|
|
|
|
|
|
|
model.keySet().stream().forEach(key -> verify(request).setAttribute(key, model.get(key))); |
|
|
|
model.forEach((key, value) -> verify(request).setAttribute(key, value)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Test |
|
|
|
@Test |
|
|
@ -116,7 +117,7 @@ public class InternalResourceViewTests { |
|
|
|
view.render(model, request, response); |
|
|
|
view.render(model, request, response); |
|
|
|
assertEquals(url, response.getIncludedUrl()); |
|
|
|
assertEquals(url, response.getIncludedUrl()); |
|
|
|
|
|
|
|
|
|
|
|
model.keySet().stream().forEach(key -> verify(request).setAttribute(key, model.get(key))); |
|
|
|
model.forEach((key, value) -> verify(request).setAttribute(key, value)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Test |
|
|
|
@Test |
|
|
@ -132,7 +133,7 @@ public class InternalResourceViewTests { |
|
|
|
view.render(model, request, response); |
|
|
|
view.render(model, request, response); |
|
|
|
assertEquals(url, response.getIncludedUrl()); |
|
|
|
assertEquals(url, response.getIncludedUrl()); |
|
|
|
|
|
|
|
|
|
|
|
model.keySet().stream().forEach(key -> verify(request).setAttribute(key, model.get(key))); |
|
|
|
model.forEach((k, v) -> verify(request).setAttribute(k, v)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|