public void testFailureSaveEmptyExpression() throws Throwable {
String pageCode = "pagina_2";
int frame = 3;
IPage page = this._pageManager.getDraftPage(pageCode);
Widget widget = page.getWidgets()[frame];
assertNull(widget);
try {
this.setUserOnSession("admin");
this.initAction("/do/Page/SpecialWidget/Navigator", "saveNavigatorConfig");
this.addParameter("pageCode", pageCode);
this.addParameter("frame", String.valueOf(frame));
this.addParameter("widgetTypeCode", "leftmenu");
this.addParameter("navSpec", "");
String result = this.executeAction();
assertEquals("input", result);
NavigatorWidgetConfigAction action = (NavigatorWidgetConfigAction) this.getAction();
assertEquals(1, action.getActionErrors().size());
} catch (Throwable t) {
throw t;
} finally {
page = this._pageManager.getDraftPage(pageCode);
page.getWidgets()[frame] = null;
this._pageManager.updatePage(page);
}
}