final HtmlSubmitInput allCompaniesButton = (HtmlSubmitInput)form.getHtmlElementById("doChangeDepartmentNames");
// Now submit the form by clicking the button
final HtmlPage resultPage = (HtmlPage)allCompaniesButton.click();
//verify the resultPage
String responseText = resultPage.asText();
//System.out.println("html-->\n" + responseText);
//check update departments
assertTrue(-1 != responseText.indexOf("Dept-"));
//also, check to not have old departments names (default name)
assertTrue(-1 == responseText.indexOf("Default Name"));