mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
75 lines
2.1 KiB
HTML
75 lines
2.1 KiB
HTML
<!DOCTYPE HTML>
|
|
<html>
|
|
<head>
|
|
<title>Test for Password Manager</title>
|
|
<script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
|
|
<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
|
<script type="text/javascript" src="pwmgr_common.js"></script>
|
|
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
|
|
</head>
|
|
<body>
|
|
Password Manager test: simple form fill
|
|
<p id="display"></p>
|
|
|
|
<div id="content" style="display: none">
|
|
<form action="formtest.js" method="get">
|
|
<p>This is form 1.</p>
|
|
<input type="text" name="uname1" value="">
|
|
<input type="password" name="pword1" value="">
|
|
|
|
<button type="submit">Submit</button>
|
|
<button type="reset"> Reset </button>
|
|
</form>
|
|
|
|
<form action="formtest.js" method="get">
|
|
<p>This is form 2.</p>
|
|
<input type="text" name="uname2" value="">
|
|
<input type="password" name="pword2" value="">
|
|
|
|
<button type="submit">Submit</button>
|
|
<button type="reset"> Reset </button>
|
|
</form>
|
|
|
|
<form action="formtest.js" method="get">
|
|
<p>This is form 3.</p>
|
|
<input type="text" name="uname3" value="">
|
|
<input type="password" name="pword3" value="">
|
|
|
|
<button type="submit">Submit</button>
|
|
<button type="reset"> Reset </button>
|
|
</form>
|
|
|
|
</div>
|
|
|
|
<pre id="test">
|
|
<script class="testbody" type="text/javascript">
|
|
|
|
/** Test for Password Manger: form fill, multiple forms. **/
|
|
|
|
// Make sure that all forms in a document are processed.
|
|
|
|
function startTest() {
|
|
// Check form 1
|
|
is($_("uname1").value, "testuser1", "Checking for filled username1");
|
|
is($_("pword1").value, "testpass1", "Checking for filled password1");
|
|
|
|
// Check form 2
|
|
is($_("uname2").value, "testuser2", "Checking for filled username2");
|
|
is($_("pword2").value, "testpass2", "Checking for filled password2");
|
|
|
|
// Check form 3
|
|
is($_("uname3").value, "testuser3", "Checking for filled username3");
|
|
is($_("pword3").value, "testpass3", "Checking for filled password3");
|
|
|
|
SimpleTest.finish();
|
|
}
|
|
|
|
window.onload = startTest;
|
|
|
|
SimpleTest.waitForExplicitFinish();
|
|
</script>
|
|
</pre>
|
|
</body>
|
|
</html>
|
|
|