ECMAScript/JavaScript System Testing
Using Selenium-IDE |
Prof. David Bernstein |
Computer Science Department |
bernstdh@jmu.edu |
input
:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head profile="http://selenium-ide.openqa.org/profiles/test-case"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <link rel="selenium.base" href="https://w3.cs.jmu.edu/" /> <title>normal</title> </head> <body> <table cellpadding="1" cellspacing="1" border="1"> <thead> <tr><td rowspan="1" colspan="3">overweight</td></tr> </thead><tbody> <tr> <td>open</td> <td>https://w3.cs.jmu.edu/bernstdh/Web/common/lectures/ecmascriptexamples/clientsidebasics/bmi-calculator.html</td> <td></td> </tr> <tr> <td>type</td> <td>id=weight</td> <td>167</td> </tr> <tr> <td>fireEvent</td> <td>id=weight</td> <td>input</td> </tr> <tr> <td>type</td> <td>id=height</td> <td>69</td> </tr> <tr> <td>fireEvent</td> <td>id=height</td> <td>input</td> </tr> <tr> <td>assertText</td> <td>id=bmi</td> <td>24.7</td> </tr> <tr> <td>assertText</td> <td>id=category</td> <td>normal</td> </tr> <tr> <td>assertAttribute</td> <td>id=category@class</td> <td>normal</td> </tr> </tbody></table> </body> </html>
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta content="text/html; charset=UTF-8" http-equiv="content-type" /> <title>BMI Calculator Test Suite</title> </head> <body> <table id="suiteTable" cellpadding="1" cellspacing="1" border="1" class="selenium"><tbody> <tr><td><b>BMI Calculator Test Suite</b></td></tr> <tr><td><a href="normal.html">normal</a></td></tr> <tr><td><a href="overweight.html">overweight</a></td></tr> </tbody></table> </body> </html>