Skip to content

Instantly share code, notes, and snippets.

@datakurre
Created April 8, 2013 04:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save datakurre/5334210 to your computer and use it in GitHub Desktop.
Save datakurre/5334210 to your computer and use it in GitHub Desktop.
*** Settings ***
Library Selenium2Library
Library String
Suite Setup Open browser about: ff_profile_dir=${CURDIR}/profile
Suite Teardown Close all browsers
*** Test Cases ***
Validate GitHub sites
[Template] Validate
https://github.com/
https://status.github.com/
*** Keywords ***
Validate
[Arguments] ${URL}
Go to ${URL}
Show errors, features and alerts
Capture page screenshot
${data} = Get errors
Log ${data}
Should be equal ${data} ${EMPTY} Wave reported errors for ${URL}
Get errors
${source} = Get source
${source} = Replace string ${source} \n ${EMPTY}
${source} = Replace string ${source} " \n
${source} = Get lines matching regexp ${source} ^ERROR:.*
[return] ${source}
Show errors, features and alerts
Execute Javascript
... return (function(){
... window.wave_viewIcons();
... return true;
... })();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment