Author: plenyi(a)redhat.com
Date: 2010-07-23 10:16:46 -0400 (Fri, 23 Jul 2010)
New Revision: 13495
Modified:
branches/enterprise/JBPAPP_5_0/src/test/ftest/examples/seamdiscs/src/org/jboss/seam/example/seamdiscs/test/selenium/SeleniumSeamDiscsTest.java
Log:
JBPAPP-4296 Fixed Seamdiscs ftest failing in Internet Explorer.
Modified:
branches/enterprise/JBPAPP_5_0/src/test/ftest/examples/seamdiscs/src/org/jboss/seam/example/seamdiscs/test/selenium/SeleniumSeamDiscsTest.java
===================================================================
---
branches/enterprise/JBPAPP_5_0/src/test/ftest/examples/seamdiscs/src/org/jboss/seam/example/seamdiscs/test/selenium/SeleniumSeamDiscsTest.java 2010-07-23
13:41:08 UTC (rev 13494)
+++
branches/enterprise/JBPAPP_5_0/src/test/ftest/examples/seamdiscs/src/org/jboss/seam/example/seamdiscs/test/selenium/SeleniumSeamDiscsTest.java 2010-07-23
14:16:46 UTC (rev 13495)
@@ -23,6 +23,8 @@
import java.text.MessageFormat;
+import com.thoughtworks.selenium.SeleniumException;
+
import org.jboss.seam.example.common.test.selenium.SeamSeleniumTest;
import org.testng.annotations.BeforeMethod;
@@ -128,8 +130,11 @@
assertTrue("This is not expected (" + expectedDiscTitle + ") album
(" + actualDiscTitle + ")!", actualDiscTitle.equals(expectedDiscTitle));
String actualReleaseDate = "";
- if (browser.isElementPresent(MessageFormat.format(ARTIST_NTH_DISC_YEAR, tableRow) +
"/attribute::value")) {
+ if (browser.isElementPresent(MessageFormat.format(ARTIST_NTH_DISC_YEAR, tableRow)))
{
+ try {
actualReleaseDate =
browser.getAttribute(MessageFormat.format(ARTIST_NTH_DISC_YEAR, tableRow) +
"@value");
+ }
+ catch (SeleniumException ex) { /* intentionally left blank */ }
assertTrue("This is not expected (" + expectedReleaseDate + ")
release date (" + actualReleaseDate + ")!",
actualReleaseDate.equals(expectedReleaseDate));
}
Show replies by date