Your SlideShare is downloading. ×
GTAC 2010 -
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

GTAC 2010 -

1,550
views

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,550
On Slideshare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
15
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Testing Dynamic Web Sites
    V. Narayan Raman
    Tyto Software
  • 2. Xpath does not query by text well
    <div>This is <b>Bold</b></div>
    //div[text()=‘This is Bold’] ?
    _div(“This is Bold”)
    Waits are needed at each step
    Explicit waits: Have to code for worst case scenario
    Implicit waits: Recover and retry
    Tester is forced to understand HTML structures and Javascript nuances.
    Common Problems
  • 3. Proxy based approach
    Injects Javascript into browser
    Any Javascript enabled browser, any OS
    Drives a real browser
    Identifies elements smartly
    Implicitly waits for AJAX, page loads and timeouts
    Sahi – Web Test Automation Tool
  • 4. //table[@id='listing']/tbody/tr[2]/td[4]/input
    //table[@id='listing']/tbody/tr[3]/td[4]/input
    Or
    _textbox(“q”, _near(_cell("Core Java")))
    _textbox(“q”, _near(_cell("Ruby for Rails")))
    XPathvs Sahi APIs
  • 5. Visible properties take precedence
    Tests should reflect what the tester sees
    Not what the developer wrote
    Frames, iframes, layouts are all developer aids to partition information. They need not be visible in tests, though they should be assertable.
    Waits are inherent in a web application and should be automatically handled
    Sahi Philosophy
  • 6. Use various visible attributes first
    Text, Value, Alt, Title etc.
    Allow identification in a context
    _checkbox(“x”, _near(_cell(“name”)))
    Allow Regular Expression and fuzzy matches
    Normalize white spaces across browsers
    Automatically look through frames and iframes.
    Sahi Identification Strategy
  • 7. The simplest possible thing
    What is not allowed by the Browser Sandbox, delegate to proxy
    File Uploads
    401 Authentication
    File downloads
    Browsers may change
    Javascript and Proxies are here to stay
    Proxy based approach
  • 8. Allows recording, debugging and object identification on any browser via injected Javascript
    Can add automation on the fly
    Even wrap flash/applets etc. when needed
    Moving between domains, even accessing multi domains in frames/iframes are possible.
    Proxy based approach
  • 9. Allows powerful Sahi APIs, normalized across browsers
    Allows monitoring of AJAX requests and Frame loads to automatically wait till no activity
    Javascript events do not require focus, allowing parallel playback
    Injected Javascript