assertThat(renderer.getSupportedContext(), is(equalTo(Constants.WIDGET_TYPE)));
}
@Test
public void render_valid() {
Widget w = new Widget();
w.setType(Constants.WIDGET_TYPE);
w.setUrl("http://example.com/widgets/1");
RegionWidget rw = new RegionWidget();
rw.setEntityId(1L);
rw.setWidget(w);
Widget wookieWidget = new Widget();
final String WIDGET_INSTANCE = "http://example.com/widgetinstances/1";
wookieWidget.setUrl(WIDGET_INSTANCE);
expect(wookieService.getWidget(null, null, w)).andReturn(wookieWidget);
replay(wookieService);
String result = renderer.render(rw, null);