adding initial first test-case and test-suite for AlternC using Selenium IDE / Selenium Server

This commit is contained in:
Benjamin Sonntag 2012-08-25 14:39:03 +00:00
parent b22dac19cc
commit 785b52882d
4 changed files with 298 additions and 0 deletions

3
.gitattributes vendored
View File

@ -513,6 +513,9 @@ po/fr/LC_MESSAGES/alternc-admintools.po -text
/quota_delete -text
/quota_init -text
/repos-to-tx.sh -text
selenium/20120826-alternc-panel-testsuite.html -text
selenium/README -text
selenium/alternc.domain-local-mail-tld.html -text
src/Makefile -text
src/alternc-check -text
src/alternc-dboptimize -text

View File

@ -0,0 +1,14 @@
<?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>Test Suite</title>
</head>
<body>
<table id="suiteTable" cellpadding="1" cellspacing="1" border="1" class="selenium"><tbody>
<tr><td><b>Test Suite</b></td></tr>
<tr><td><a href="alternc.domain-local-mail-tld.html">alternc.domain-local-mail-tld</a></td></tr>
</tbody></table>
</body>
</html>

9
selenium/README Normal file
View File

@ -0,0 +1,9 @@
The following files are selenium test suites
the <date>-*.html files are complete test suites
the *.html files are individual tests.
use Selenium IDE and Selenium Server to manage / run those tests.
The AlternC's panel is supposed to run at http://ac.local/

View File

@ -0,0 +1,272 @@
<?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="http://ac.local" />
<title>alternc.domain-local-mail-tld</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">alternc.domain-local-mail-tld</td></tr>
</thead><tbody>
<tr>
<td>open</td>
<td>/</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>To connect to the hosting control panel</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>id=username</td>
<td>admin</td>
</tr>
<tr>
<td>type</td>
<td>id=password</td>
<td>admin</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=submit</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>Last Login:</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=Add a domain</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//div[@id='menu-adm']/ul/li[3]/a/span</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=Manage allowed domains (TLD)</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>xpath=(//a[contains(text(),'Add a new TLD')])[2]</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>id=tld</td>
<td>local</td>
</tr>
<tr>
<td>select</td>
<td>id=mode</td>
<td>label=Domain can be installed, no check at all</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>css=input.inb</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>The TLD has been successfully added</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=Add a domain</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>host my dns here</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>id=newdomain</td>
<td>alternc.local</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=submit</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td> Your new domain alternc.local has been successfully installed</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=Click here to continue</td>
<td></td>
</tr>
<tr>
<td>pause</td>
<td>waitTime=5000</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//div[@id='menu-mail']/ul/li/a</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>Create a new mail account</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>id=mail_arg</td>
<td>test</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=submit</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>Editing the email test@alternc.local</td>
<td></td>
</tr>
<tr>
<td>click</td>
<td>id=islocal1</td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>id=pass</td>
<td>test</td>
</tr>
<tr>
<td>type</td>
<td>id=passconf</td>
<td>test</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=submit</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>The password policy prevents you to use your login name inside your password </td>
<td></td>
</tr>
<tr>
<td>type</td>
<td>id=pass</td>
<td>CoinCoin</td>
</tr>
<tr>
<td>type</td>
<td>id=passconf</td>
<td>CoinCoin</td>
</tr>
<tr>
<td>type</td>
<td>id=quotamb</td>
<td>10</td>
</tr>
<tr>
<td>type</td>
<td>id=recipients</td>
<td>test2@alternc.local</td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=submit</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>Your email has been edited successfully</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>test2@alternc.local</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=alternc.local</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=detruire</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>Confirm the deletion of domain alternc.local</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>name=submit</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td> The domain alternc.local has been successfully deleted.</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=Click here to continue</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//div[@id='menu-adm']/ul/li[3]/a/span</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=Manage allowed domains (TLD)</td>
<td></td>
</tr>
<tr>
<td>click</td>
<td>id=sel10</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>//input[@value='Delete the checked TLD']</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>The requested TLD has been deleted</td>
<td></td>
</tr>
<tr>
<td>clickAndWait</td>
<td>link=Home / Information</td>
<td></td>
</tr>
<tr>
<td>verifyTextPresent</td>
<td>Account admin</td>
<td></td>
</tr>
</tbody></table>
</body>
</html>