HtmlDivision card1Div = cardDivs.get(0);
HtmlDivision card2Div = cardDivs.get(1);
HtmlDivision card3Div = cardDivs.get(2);
HtmlAnchor detailsLink = getFirstLinkByText(card1Div, "card1");
detailsLink.click();
testTitle(page, "Cards");
testBasics(page);
assertTrue(page.getHtmlElementById("cardDetails").asText().contains("card1"));
testElementNotPresent(page, "createCardForm");
testElementNotPresent(page, "modifyCardForm");
testElementNotPresent(page, "deleteCardForm");
HtmlAnchor modifyLink = getFirstLinkByTitle(card2Div, "Modify card");
modifyLink.click();
assertTrue(page.getHtmlElementById("cardDetails").asText().contains("card2"));
testElementNotPresent(page, "createCardForm");
assertNotNull(page.getHtmlElementById("modifyCardForm"));
testElementNotPresent(page, "deleteCardForm");
HtmlAnchor deleteLink = getFirstLinkByTitle(card3Div, "Delete card");
deleteLink.click();
assertTrue(page.getHtmlElementById("cardDetails").asText().contains("card3"));
testElementNotPresent(page, "createCardForm");
testElementNotPresent(page, "modifyCardForm");
assertNotNull(page.getHtmlElementById("deleteCardForm"));
}