Your SlideShare is downloading. ×
0
Interpreter Pattern Inside Selenium Core David Kemp, March 2008
Talk Outline <ul><li>Description of the Interpreter Pattern </li></ul><ul><li>Introduction to Selenium </li></ul><ul><li>S...
Interpreter Pattern <ul><li>Represent instances of a grammar using object composition. </li></ul><ul><li>Note: It does NOT...
Example from Kerievsky
Example Continued… <ul><li>Price < 43 AND NOT Colour = Blue </li></ul>
Selenium <ul><li>Web Testing Tool </li></ul><ul><li>Free and Open Source </li></ul><ul><li>Developed by ThoughtWorks and “...
Selenium Core
Selenium Remote Control browser.open(&quot;http://www.google.com/webhp?hl=en&quot;); browser.type(&quot;q&quot;, &quot;hel...
Selenium Remote Control
Grammar for assert, verify, store, and waitFor commands Example Commands: assertValue, assertNotValue, storeValue, waitFor...
Selenium HTML Runner
Example Command Handler: assertNotValue
Upcoming SlideShare
Loading in...5
×

Selenium Interpreter

1,143

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,143
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
38
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Transcript of "Selenium Interpreter"

  1. 1. Interpreter Pattern Inside Selenium Core David Kemp, March 2008
  2. 2. Talk Outline <ul><li>Description of the Interpreter Pattern </li></ul><ul><li>Introduction to Selenium </li></ul><ul><li>Selenium’s Design </li></ul><ul><li>Selenium’s usage of Interpreter </li></ul>
  3. 3. Interpreter Pattern <ul><li>Represent instances of a grammar using object composition. </li></ul><ul><li>Note: It does NOT address parsing. </li></ul>
  4. 4. Example from Kerievsky
  5. 5. Example Continued… <ul><li>Price < 43 AND NOT Colour = Blue </li></ul>
  6. 6. Selenium <ul><li>Web Testing Tool </li></ul><ul><li>Free and Open Source </li></ul><ul><li>Developed by ThoughtWorks and “Friends” </li></ul><ul><li>Recorders Exist </li></ul><ul><li>Can be driven by: Java, .NET, Perl, PHP, Python, Ruby, and HTML . </li></ul>
  7. 7. Selenium Core
  8. 8. Selenium Remote Control browser.open(&quot;http://www.google.com/webhp?hl=en&quot;); browser.type(&quot;q&quot;, &quot;hello world&quot;); browser.click(&quot;btnG&quot;); browser.waitForPageToLoad(&quot;5000&quot;); assertEquals(&quot;hello world - Google Search&quot;, browser.getTitle());
  9. 9. Selenium Remote Control
  10. 10. Grammar for assert, verify, store, and waitFor commands Example Commands: assertValue, assertNotValue, storeValue, waitForValue, waitForNotValue, assertText, assertNotText, storeText,…, assertAttribute, assertNotAttribute, storeAttribute… etc. etc. General Form: command = {action}{accessor} | {action} Not {accessor} action = assert | verify | store | waitFor accessor = value | text | attribute | title | visible | elementPresent | textPresent …
  11. 11. Selenium HTML Runner
  12. 12. Example Command Handler: assertNotValue
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×