{"id":600,"date":"2011-10-27T11:01:00","date_gmt":"2011-10-27T11:01:00","guid":{"rendered":"http:\/\/www.javacodegeeks.com\/2012\/10\/testing-gwt-apps-with-selenium-or-webdriver.html"},"modified":"2012-10-21T20:23:34","modified_gmt":"2012-10-21T20:23:34","slug":"testing-gwt-apps-with-selenium-or","status":"publish","type":"post","link":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html","title":{"rendered":"Testing GWT Apps with Selenium or WebDriver"},"content":{"rendered":"<div dir=\"ltr\" style=\"text-align: left\">Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are cheap to maintain and yet provide good test coverage, which helps reduce QA costs and increase quality.<\/p>\n<p>Both Selenium and WebDriver (which is essentially now the successor to Selenium) provide a good way to functionally test web applications in multiple target environments without manual work. In the past, web UIs were built using the page navigation to allow users to submit forms, etc. These days, more and more web applications use Ajax and therefore act and look a lot more like desktop applications. However, this poses problems for testing \u2013 Selenium and WebDriver are designed to work with user interations resulting in page navigation and don\u2019t play well with AJAX apps out of the box.<\/p>\n<p>GWT-based applications in particular have this problem, but there are some ways I\u2019ve found to develop useful and effective tests. GWT also poses other issues in regards to simulating user input and locating DOM elements, and I discuss those below. Note that my code examples use Groovy to make them concise, but they can be pretty easily converted to Java code.<\/p>\n<p><strong>Problem 1: Handling Asynchronous Changes<\/strong><\/p>\n<p>One issue that developers face pretty quickly when testing applications based on GWT is detecting and waiting for a response to user interaction. For example, a user may click a button which results in an AJAX call which would either succeed and close a window or, alternatively, show an error message. What we need is a way to block until we see the expected changes, with a timeout so we can fail if we don\u2019t see the expected changes.<\/p>\n<p><strong>Solution: Use WebDriverWait<\/strong><\/p>\n<p>The easiest way to do this is by taking advantage of the WebDriverWait (or Selenium\u2019s Wait). This allows you to wait on a condition and proceed when it evaluates to true. Below I use Groovy code for the conciseness of using closures, but the same can be done in Java, though with a bit more code due to the need for anonymous classes.<\/p>\n<pre class=\"brush: java\">def waitForCondition(Closure closure) {\r\n    int timeout = 20\r\n    WebDriverWait w = new WebDriverWait(driver, timeout)\r\n    w.until({\r\n        closure() \/\/ wait until this closure evaluates to true\r\n    } as ExpectedCondition)\r\n}\r\n\r\ndef waitForElement(By finder) {\r\n    waitForCondition {\r\n        driver.findElements(finder).size() &gt; 0;\r\n    }\r\n}\r\n\r\ndef waitForElementRemoval(By finder) {\r\n    waitForCondition {\r\n        driver.findElements(finder).size() == 0;\r\n    }\r\n}\r\n\r\n\/\/ now some sample test code \r\n\r\nsubmitButton.click() \/\/ submit a form\r\n\r\n\/\/ wait for the expected error summary to show up\r\nwaitForElement(By.xpath(\"\/\/div[@class='error-summary']\"))\r\n\/\/ maybe some more verification here to check the expected errors\r\n\r\n\/\/ ... correct error and resubmit\r\n\r\nsubmitButton.click()\r\nwaitForElementRemoval(By.xpath(\"\/\/div[@class='error-summary']\"))\r\nwaitForElementRemoval(By.id(\"windowId\"))\r\n<\/pre>\n<p>As you can see from the example, your code can focus on the actual test logic while handling the asynchronous nature of GWT applications seamlessly.<div style=\"display:inline-block; margin: 15px 0;\"> <div id=\"adngin-JavaCodeGeeks_incontent_video-0\" style=\"display:inline-block;\"><\/div> <\/div><\/p>\n<p><strong>Problem 2: Locating Elements when you have little control over DOM<\/strong><\/p>\n<p>In web applications that use templating (JSPs, Velocity, JSF, etc.), you have good control and easy visibility into the DOM structure that your pages will have. With GWT, this isn\u2019t always the case. Often, you\u2019re dealing with nested elements that you can\u2019t control at a fine level.<\/p>\n<p>With WebDriver and Selenium, you can target elements using a few methods, but the most useful are by DOM element ID and XPath. How can we leverage these to get maintainable tests that don\u2019t break with minor layout changes?<\/p>\n<p><strong>Solution: Use XPath combined with IDs to limit scope<\/strong><\/p>\n<p>In my experience, to develop functional GWT tests in WebDriver, you should use somewhat loose XPath as your primary means of locating elements, and supplement it by scoping these calls by DOM ID, where applicable.<\/p>\n<p>In particular, use IDs at top level elements like windows or tabs that are unique in your application and won\u2019t exist more than once in a page. These can help scope your XPath expressions, which can look for window or form titles, field labels, etc.<\/p>\n<p>Here are some examples to get you going. Note that we use \/\/ and * in our XPath to keep our expressions flexible so that layout changes do not break our tests unless they are major.<\/p>\n<pre class=\"brush: java\">By byUserName = By.xpath(\"\/\/*[@id='userTab']\/\/*[text()='User Name']\/..\/\/input\")\r\nWebElement userNameField = webDriver.findElement(byUserName)\r\nuserNameField.sendKeys(\"my new user\")\r\n\r\n\/\/ maybe a user click and then wait for the window to disappear\r\nBy submitLocator = By.xpath(\"\/\/*[@id='userTab']\/\/input[@type='submit']\")\r\nWebElement submit = webDriver.findElement(submitLocator)\r\nsubmit.click()\r\n\r\n\/\/ use our helper method from Problem 1\r\nwaitForElementRemoval By.id(\"userTab\")\r\n<\/pre>\n<p><strong>Problem 3: Normal element interaction methods don\u2019t work!<\/strong><\/p>\n<p>GWT and derivatives (Vaadin, GXT, etc.) often are doing some magic behind the scenes as far as managing the state of the DOM goes. To the developer, this means you\u2019re not always dealing with plain &lt;input&gt; or &lt;select&gt;, etc. elements. Simply setting the value of the field through normal means may not work, and using WebDriver or Selenium\u2019s click methods may not work.<\/p>\n<p>WebDriver has improved in this regard, but issues still persist.<\/p>\n<p><strong>Solution: Unfortunately, just some workarounds<\/strong><\/p>\n<p>The main problems you\u2019re likely to encounter relate to typing into fields and clicking elements.<\/p>\n<p>Here are some variants that I have found necessary in the past to get around clicks not working as expected. Try them if you are hitting issues. The examples are in Selenium, but they can be adapted to the corresponding calls in WebDriver if you require them. You may also use the Selenium adapter for WebDriver (WebDriverBackedSelenium) if you want to use the examples directly.<\/p>\n<p><i><strong>CLICK ISSUES<\/strong><\/i><br \/>\nSometimes elements won\u2019t respond to a click() call in Selenium or WebDriver. In these cases, you usually have to simulate events in the browser. This was true more of Selenium before 2.0 than WebDriver.<\/p>\n<pre class=\"brush: java\">\/\/ Selenium's click sometimes has to be simulated with events.\r\ndef fullMouseClick(String locator) {\r\n    selenium.mouseOver locator\r\n    selenium.mouseDown locator\r\n    selenium.mouseUp locator\r\n}\r\n\r\n\/\/ In some cases you need only mouseDown, as mouseUp may be\r\n\/\/ handled the same as mouseDown.\r\n\/\/ For example, this could result in a table row being selected, then deselected.\r\ndef mouseOverAndDown(String locator) {\r\n    selenium.mouseOver locator\r\n    selenium.mouseDown locator\r\n}\r\n<\/pre>\n<p><i><strong>TYPING ISSUES<\/strong><\/i><br \/>\nThese are the roundabout methods of typing I have been able to use successfully in the past when GWT doesn\u2019t recognize typed input.<\/p>\n<pre class=\"brush: java\">\/\/ fires only key events (works for most GWT inputs)\r\n\/\/ Useful if WebDriver sendKeys() or Selenium type() aren't cooperating.\r\ndef typeWithEvents(String locator, String text) {\r\n    def keyEvents = [\"keydown\", \"keypress\", \"keyup\"]\r\n    typeWithEvents(locator, text, keyEvents)\r\n}\r\n\r\n\/\/ fires key events, plus blur and focus for really picky cases\r\ndef typeWithFullEvents(String locator, String text) {\r\n    def fullEvents = [\"keydown\", \"keypress\", \"keyup\", \"blur\", \"focus\"]\r\n    typeWithEvents(locator, text, fullEvents)\r\n}\r\n\r\n\/\/ use this directly to customize which events are fired\r\ndef typeWithEvents(String locator, String text, def events) {\r\n    text.eachWithIndex { ch, i -&gt;\r\n        selenium.type locator, text.substring(0, i+1)\r\n        events.each{ event -&gt;\r\n            selenium.fireEvent locator, event\r\n        }\r\n    }\r\n}\r\n<\/pre>\n<p>Note that the exact method that works will have to be figured out by trial-and-error and in some cases, you may get different behaviour in different browsers, so if you run your functional tests against different environments, you\u2019ll have to ensure your method works for all of them.<\/p>\n<p><strong>Conclusion<\/strong><\/p>\n<p>Hopefully some of you find these tips useful. There are similar tips out there but I wanted to compile a good set of examples and workarounds so that others in similar situations don\u2019t hit dead-ends or waste time on problems that require lots of guessing and time.<\/p>\n<p><strong><i>Reference: <\/i><\/strong><a href=\"http:\/\/www.carfey.com\/blog\/testing-gwt-apps-with-selenium-or-webdriver\/\">Testing GWT Apps with Selenium or WebDriver<\/a> from our <a href=\"http:\/\/www.javacodegeeks.com\/p\/jcg.html\">JCG partner<\/a>s at the <a href=\"http:\/\/www.carfey.com\/blog\/\">Carfey Software blog<\/a>.<\/p>\n<div style=\"margin: 0px\"><strong><i>Related Articles :<\/i><\/strong><\/div>\n<ul>\n<li><a href=\"http:\/\/www.javacodegeeks.com\/2011\/10\/services-practices-tools-that-should_18.html\">Services, practices &amp; tools that should exist in any software development house, part 2<\/a><\/li>\n<li><a href=\"http:\/\/www.javacodegeeks.com\/2011\/04\/automated-tests-boost-development-speed.html\">Why Automated Tests Boost Your Development Speed<\/a><\/li>\n<li><a href=\"http:\/\/www.javacodegeeks.com\/2011\/06\/not-doing-code-reviews-whats-your.html\">Not doing Code Reviews? What\u2019s your excuse?<\/a><\/li>\n<li><a href=\"http:\/\/www.javacodegeeks.com\/2011\/06\/lessons-in-software-reliability.html\">Lessons in Software Reliability<\/a> <\/li>\n<li><a href=\"http:\/\/www.javacodegeeks.com\/2011\/09\/this-comes-before-your-business-logic.html\">This comes BEFORE your business logic!<\/a><\/li>\n<li><a href=\"http:\/\/www.javacodegeeks.com\/2011\/10\/code-coverage-with-unit-integration.html\">Code coverage with unit &amp; integration tests<\/a><\/li>\n<\/ul>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are cheap to maintain and yet provide good test coverage, which helps reduce QA costs and increase quality. Both Selenium and WebDriver (which is essentially now the successor to Selenium) &hellip;<\/p>\n","protected":false},"author":59,"featured_media":125,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[27,287,273,286],"class_list":["post-600","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-enterprise-java","tag-google-gwt","tag-selenium","tag-testing","tag-webdriver"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Testing GWT Apps with Selenium or WebDriver - Java Code Geeks<\/title>\n<meta name=\"description\" content=\"Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Testing GWT Apps with Selenium or WebDriver - Java Code Geeks\" \/>\n<meta property=\"og:description\" content=\"Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html\" \/>\n<meta property=\"og:site_name\" content=\"Java Code Geeks\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/javacodegeeks\" \/>\n<meta property=\"article:published_time\" content=\"2011-10-27T11:01:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2012-10-21T20:23:34+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2012\/10\/google-gwt-logo.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"150\" \/>\n\t<meta property=\"og:image:height\" content=\"150\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Craig Flichel\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@javacodegeeks\" \/>\n<meta name=\"twitter:site\" content=\"@javacodegeeks\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Craig Flichel\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"7 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html\"},\"author\":{\"name\":\"Craig Flichel\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#\\\/schema\\\/person\\\/c1bcd58320330b548e07d846510f9460\"},\"headline\":\"Testing GWT Apps with Selenium or WebDriver\",\"datePublished\":\"2011-10-27T11:01:00+00:00\",\"dateModified\":\"2012-10-21T20:23:34+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html\"},\"wordCount\":1007,\"commentCount\":1,\"publisher\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.javacodegeeks.com\\\/wp-content\\\/uploads\\\/2012\\\/10\\\/google-gwt-logo.jpg\",\"keywords\":[\"Google GWT\",\"Selenium\",\"Testing\",\"WebDriver\"],\"articleSection\":[\"Enterprise Java\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html\",\"url\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html\",\"name\":\"Testing GWT Apps with Selenium or WebDriver - Java Code Geeks\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.javacodegeeks.com\\\/wp-content\\\/uploads\\\/2012\\\/10\\\/google-gwt-logo.jpg\",\"datePublished\":\"2011-10-27T11:01:00+00:00\",\"dateModified\":\"2012-10-21T20:23:34+00:00\",\"description\":\"Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#primaryimage\",\"url\":\"https:\\\/\\\/www.javacodegeeks.com\\\/wp-content\\\/uploads\\\/2012\\\/10\\\/google-gwt-logo.jpg\",\"contentUrl\":\"https:\\\/\\\/www.javacodegeeks.com\\\/wp-content\\\/uploads\\\/2012\\\/10\\\/google-gwt-logo.jpg\",\"width\":150,\"height\":150},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/2011\\\/10\\\/testing-gwt-apps-with-selenium-or.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.javacodegeeks.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Java\",\"item\":\"https:\\\/\\\/www.javacodegeeks.com\\\/category\\\/java\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Enterprise Java\",\"item\":\"https:\\\/\\\/www.javacodegeeks.com\\\/category\\\/java\\\/enterprise-java\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Testing GWT Apps with Selenium or WebDriver\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#website\",\"url\":\"https:\\\/\\\/www.javacodegeeks.com\\\/\",\"name\":\"Java Code Geeks\",\"description\":\"Java Developers Resource Center\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#organization\"},\"alternateName\":\"JCG\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.javacodegeeks.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#organization\",\"name\":\"Exelixis Media P.C.\",\"url\":\"https:\\\/\\\/www.javacodegeeks.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.javacodegeeks.com\\\/wp-content\\\/uploads\\\/2022\\\/06\\\/exelixis-logo.png\",\"contentUrl\":\"https:\\\/\\\/www.javacodegeeks.com\\\/wp-content\\\/uploads\\\/2022\\\/06\\\/exelixis-logo.png\",\"width\":864,\"height\":246,\"caption\":\"Exelixis Media P.C.\"},\"image\":{\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/javacodegeeks\",\"https:\\\/\\\/x.com\\\/javacodegeeks\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.javacodegeeks.com\\\/#\\\/schema\\\/person\\\/c1bcd58320330b548e07d846510f9460\",\"name\":\"Craig Flichel\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f7ada05eac86c369123683747aa5f714e262e52d4af354efe8aba14f76075dc4?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f7ada05eac86c369123683747aa5f714e262e52d4af354efe8aba14f76075dc4?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f7ada05eac86c369123683747aa5f714e262e52d4af354efe8aba14f76075dc4?s=96&d=mm&r=g\",\"caption\":\"Craig Flichel\"},\"sameAs\":[\"http:\\\/\\\/www.carfey.com\\\/blog\\\/\"],\"url\":\"https:\\\/\\\/www.javacodegeeks.com\\\/author\\\/Craig-Flichel\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Testing GWT Apps with Selenium or WebDriver - Java Code Geeks","description":"Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html","og_locale":"en_US","og_type":"article","og_title":"Testing GWT Apps with Selenium or WebDriver - Java Code Geeks","og_description":"Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are","og_url":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html","og_site_name":"Java Code Geeks","article_publisher":"https:\/\/www.facebook.com\/javacodegeeks","article_published_time":"2011-10-27T11:01:00+00:00","article_modified_time":"2012-10-21T20:23:34+00:00","og_image":[{"width":150,"height":150,"url":"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2012\/10\/google-gwt-logo.jpg","type":"image\/jpeg"}],"author":"Craig Flichel","twitter_card":"summary_large_image","twitter_creator":"@javacodegeeks","twitter_site":"@javacodegeeks","twitter_misc":{"Written by":"Craig Flichel","Est. reading time":"7 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#article","isPartOf":{"@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html"},"author":{"name":"Craig Flichel","@id":"https:\/\/www.javacodegeeks.com\/#\/schema\/person\/c1bcd58320330b548e07d846510f9460"},"headline":"Testing GWT Apps with Selenium or WebDriver","datePublished":"2011-10-27T11:01:00+00:00","dateModified":"2012-10-21T20:23:34+00:00","mainEntityOfPage":{"@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html"},"wordCount":1007,"commentCount":1,"publisher":{"@id":"https:\/\/www.javacodegeeks.com\/#organization"},"image":{"@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#primaryimage"},"thumbnailUrl":"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2012\/10\/google-gwt-logo.jpg","keywords":["Google GWT","Selenium","Testing","WebDriver"],"articleSection":["Enterprise Java"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html","url":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html","name":"Testing GWT Apps with Selenium or WebDriver - Java Code Geeks","isPartOf":{"@id":"https:\/\/www.javacodegeeks.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#primaryimage"},"image":{"@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#primaryimage"},"thumbnailUrl":"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2012\/10\/google-gwt-logo.jpg","datePublished":"2011-10-27T11:01:00+00:00","dateModified":"2012-10-21T20:23:34+00:00","description":"Good functional testing is one of the most difficult tasks for web application developers and their teams. It is a challenge to develop tests that are","breadcrumb":{"@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#primaryimage","url":"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2012\/10\/google-gwt-logo.jpg","contentUrl":"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2012\/10\/google-gwt-logo.jpg","width":150,"height":150},{"@type":"BreadcrumbList","@id":"https:\/\/www.javacodegeeks.com\/2011\/10\/testing-gwt-apps-with-selenium-or.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.javacodegeeks.com\/"},{"@type":"ListItem","position":2,"name":"Java","item":"https:\/\/www.javacodegeeks.com\/category\/java"},{"@type":"ListItem","position":3,"name":"Enterprise Java","item":"https:\/\/www.javacodegeeks.com\/category\/java\/enterprise-java"},{"@type":"ListItem","position":4,"name":"Testing GWT Apps with Selenium or WebDriver"}]},{"@type":"WebSite","@id":"https:\/\/www.javacodegeeks.com\/#website","url":"https:\/\/www.javacodegeeks.com\/","name":"Java Code Geeks","description":"Java Developers Resource Center","publisher":{"@id":"https:\/\/www.javacodegeeks.com\/#organization"},"alternateName":"JCG","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.javacodegeeks.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.javacodegeeks.com\/#organization","name":"Exelixis Media P.C.","url":"https:\/\/www.javacodegeeks.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.javacodegeeks.com\/#\/schema\/logo\/image\/","url":"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png","contentUrl":"https:\/\/www.javacodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png","width":864,"height":246,"caption":"Exelixis Media P.C."},"image":{"@id":"https:\/\/www.javacodegeeks.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/javacodegeeks","https:\/\/x.com\/javacodegeeks"]},{"@type":"Person","@id":"https:\/\/www.javacodegeeks.com\/#\/schema\/person\/c1bcd58320330b548e07d846510f9460","name":"Craig Flichel","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/f7ada05eac86c369123683747aa5f714e262e52d4af354efe8aba14f76075dc4?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/f7ada05eac86c369123683747aa5f714e262e52d4af354efe8aba14f76075dc4?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/f7ada05eac86c369123683747aa5f714e262e52d4af354efe8aba14f76075dc4?s=96&d=mm&r=g","caption":"Craig Flichel"},"sameAs":["http:\/\/www.carfey.com\/blog\/"],"url":"https:\/\/www.javacodegeeks.com\/author\/Craig-Flichel"}]}},"_links":{"self":[{"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/posts\/600","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/users\/59"}],"replies":[{"embeddable":true,"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/comments?post=600"}],"version-history":[{"count":0,"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/posts\/600\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/media\/125"}],"wp:attachment":[{"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/media?parent=600"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/categories?post=600"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.javacodegeeks.com\/wp-json\/wp\/v2\/tags?post=600"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}