public void testUploadDownloadTwoAttachments()
{
ViewPage vp = getUtil().createPage(getTestClassName(), getTestMethodName(), null,
getTestClassName() + "#" + getTestMethodName());
AttachmentsPane ap = vp.openAttachmentsDocExtraPane();
ap.setFileToUpload(this.getClass().getResource("/" + this.testAttachment).getPath());
ap.addAnotherFile();
ap.setFileToUpload(this.getClass().getResource("/" + this.testAttachment2).getPath());
ap.clickAttachFiles();
Assert.assertEquals("1.1", ap.getLatestVersionOfAttachment(this.testAttachment));
Assert.assertEquals("1.1", ap.getLatestVersionOfAttachment(this.testAttachment2));
// Verify attachment contents
ap.getAttachmentLink(this.testAttachment).click();
Assert.assertEquals("This is a small attachment.", getDriver().findElement(By.tagName("html")).getText());
getDriver().navigate().back();
ap.getAttachmentLink(this.testAttachment2).click();
Assert.assertEquals("This is another small attachment.", getDriver().findElement(By.tagName("html")).getText());
}