@Test(groups = "web")
 public void testListLeftMenu() throws IOException {
   tester.clickLinkWithText(getProperty("menuItem.lists"));
   tester.assertTextPresent(getProperty("pageTitle.listOfDefinitions"));
   tester.assertLinkPresentWithText(getProperty("menuItem.hardwareDefinitions"));
   tester.assertLinkPresentWithText(getProperty("menuItem.optionalParametersForPeople"));
   tester.assertLinkPresentWithText(getProperty("menuItem.optionalParametersForExperiments"));
   tester.assertLinkPresentWithText(getProperty("menuItem.fileMetadataDefinitions"));
   tester.assertLinkPresentWithText(getProperty("menuItem.weatherDefinitions"));
   tester.assertLinkPresentWithText(getProperty("menuItem.artifactDefinitions"));
   // TODO other definitions (sw, disease, pharmaceuticals, ...)
   tester.clickLinkWithText(getProperty("action.logout"));
 }
  @Test(groups = "web")
  public void testListDefaultGroupsValidationAdmin() throws IOException {
    tester.clickLinkWithText(getProperty("menuItem.lists"));
    tester.assertTextPresent(getProperty("pageTitle.listOfDefinitions"));
    tester.assertLinkPresentWithText(getProperty("menuItem.hardwareDefinitions"));
    tester.clickLinkWithText(getProperty("menuItem.hardwareDefinitions"));
    tester.assertSelectOptionPresent("groups", "Default hardware");

    tester.clickLinkWithText(getProperty("menuItem.optionalParametersForPeople"));
    tester.assertSelectOptionPresent("groups", "Default optional parameters");

    tester.clickLinkWithText(getProperty("menuItem.optionalParametersForExperiments"));
    tester.assertSelectOptionPresent("groups", "Default optional parameters");

    tester.clickLinkWithText(getProperty("menuItem.fileMetadataDefinitions"));
    tester.assertSelectOptionPresent("groups", "Default metadata parameters");

    tester.clickLinkWithText(getProperty("menuItem.weatherDefinitions"));
    tester.assertSelectOptionPresent("groups", "Default weather");

    tester.clickLinkWithText(
        getProperty("menuItem.artifactDefinitions")); // Artifact do not have the Default group
    tester.assertSelectOptionNotPresent("groups", "Default artifact");

    tester.clickLinkWithText(getProperty("action.logout"));
  }
  @Test(groups = "web")
  public void testListDefaultGroupsValidationUser() throws IOException {
    tester.clickLinkWithText(getProperty("action.logout"));
    if (!personDao.usernameExists("*****@*****.**")) {
      Person person = TestUtils.createPersonForTesting("*****@*****.**", Util.ROLE_USER);
      person.setConfirmed(true);
      personDao.create(person);
    }
    tester.setTextField("userName", "*****@*****.**");
    tester.setTextField("password", "stebjan");
    tester.clickButtonWithText(getProperty("action.login"));
    tester.assertTextPresent(getProperty("action.logout"));

    tester.clickLinkWithText(getProperty("menuItem.lists"));
    tester.assertTextPresent(getProperty("pageTitle.listOfDefinitions"));
    tester.assertLinkPresentWithText(getProperty("menuItem.hardwareDefinitions"));
    tester.clickLinkWithText(getProperty("menuItem.hardwareDefinitions"));
    tester.assertSelectOptionNotPresent("groups", "Default hardware");

    tester.clickLinkWithText(getProperty("menuItem.optionalParametersForPeople"));
    tester.assertSelectOptionNotPresent("groups", "Default optional parameters");

    tester.clickLinkWithText(getProperty("menuItem.optionalParametersForExperiments"));
    tester.assertSelectOptionNotPresent("groups", "Default optional parameters");

    tester.clickLinkWithText(getProperty("menuItem.fileMetadataDefinitions"));
    tester.assertSelectOptionNotPresent("groups", "Default metadata parameters");

    tester.clickLinkWithText(getProperty("menuItem.weatherDefinitions"));
    tester.assertSelectOptionNotPresent("groups", "Default weather");

    tester.clickLinkWithText(getProperty("action.logout"));
  }
  @Test
  public void Test19_AddTerm_page2() {
    tester.beginAt("index.php");
    tester.setTextField("username", TestKeys.USER_ADMIN);
    tester.setTextField("password", TestKeys.USER_ADMIN);
    tester.submit();

    tester.assertMatch("Manage Classes");

    tester.clickLinkWithText("Terms");
    tester.assertMatch("Manage Terms");

    tester.setWorkingForm("terms");
    tester.setTextField("page2", "8'> <a href=\"http://unitn.it\">XSS</a> </ br '");
    tester.setTextField("page", "1");

    // add submit button
    TestUtil.addFormSubmitButton(tester, "terms");
    tester.submit();

    tester.assertMatch("Add New Term");

    tester.assertLinkNotPresentWithText("XSS");
  }