Add an example test that utilizes MasterQA
This commit is contained in:
parent
0942410795
commit
30fb7e3ca4
|
@ -0,0 +1,25 @@
|
|||
from seleniumbase import MasterQA
|
||||
|
||||
|
||||
class MasterQATests(MasterQA):
|
||||
|
||||
def test_xkcd(self):
|
||||
self.open("http://xkcd.com/1512/")
|
||||
for i in xrange(4):
|
||||
self.click('a[rel="next"]')
|
||||
for i in xrange(3):
|
||||
self.click('a[rel="prev"]')
|
||||
self.verify()
|
||||
self.open("http://xkcd.com/1520/")
|
||||
for i in xrange(2):
|
||||
self.click('a[rel="next"]')
|
||||
self.verify("Can you find the moon?")
|
||||
self.click('a[rel="next"]')
|
||||
self.verify("Do the drones look safe?")
|
||||
self.click_link_text('Blag')
|
||||
self.update_text("input#s", "Robots!\n")
|
||||
self.verify("Does it say 'Hooray robots' on the page?")
|
||||
self.open("http://xkcd.com/213/")
|
||||
for i in xrange(5):
|
||||
self.click('a[rel="prev"]')
|
||||
self.verify("Does the page say 'Abnormal Expressions'?")
|
Loading…
Reference in New Issue