Skip to content

Commit 945999c

Browse files
committed
Sanitize submit text.
- Add all issue supporting files for future tests.
1 parent f2d6558 commit 945999c

File tree

6 files changed

+59
-2
lines changed

6 files changed

+59
-2
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
### 1.2.5 (2015.09.22)
2+
3+
* Bugfixes
4+
15
### 1.2.4 (2015.08.28)
26

37
* Bugfixes

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "selenium-page-object-generator",
3-
"version": "1.2.4",
3+
"version": "1.2.5",
44
"description": "A nimble and flexible Selenium Page Object Model generator to improve agile testing process velocity.",
55
"dependencies": {},
66
"devDependencies": {

specs/issues/001.html

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<body>
4+
<h1>Debiana</h1>
5+
<label for="UserName">User Name</label>
6+
<br>
7+
<input maxlength="50" autocomplete="off" class="textfield" id="username" name="username" type="text" value>
8+
<br>
9+
<label for="Password">Password</label>
10+
<br>
11+
<input maxlength="25" autocomplete="off" class="textfield" id="password" name="password" type="password">
12+
<br>
13+
<!--
14+
[FindsBy(How = How.Id, Using = "username")] [CacheLookup] private IWebElement debianaUserNamePassword1;
15+
[FindsBy(How = How.Id, Using = "password")] [CacheLookup] private IWebElement debianaUserNamePassword2;
16+
-->
17+
</body>
18+
</html>

specs/issues/002.html

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<style>
5+
.container {
6+
border: 1px solid blue;
7+
}
8+
</style>
9+
</head>
10+
<body>
11+
<div class="container">
12+
<input type="checkbox" id="cat_someLongId1"/> This is checkbox 1<br/>
13+
<input type="checkbox" id="cat_someLongId2"/> This is checkbox 2<br/>
14+
<input type="checkbox" id="cat_someLongId3"/> This is checkbox 3<br/>
15+
<input type="checkbox" id="cat_someLongId4"/> This is checkbox 4<br/>
16+
<input type="checkbox" id="cat_someLongId5"/> This is checkbox 5<br/>
17+
</div>
18+
<input type="checkbox" id="other"/> This is the other checkbox<br/>
19+
</body>
20+
</html>

specs/issues/003.html

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
</head>
5+
<body>
6+
<input value="I'm Feeling Lucky" aria-label="I'm Feeling Lucky" id="gbqfbb" name="btnI" type="submit">
7+
<!--
8+
public GoogleHomePage submit() {
9+
clickI&#x27;mFeelingLuckyButton();
10+
return this;
11+
}
12+
-->
13+
</body>
14+
</html>

src/chrome/assets/js/generator.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -796,7 +796,8 @@ window.POG=(function() {
796796
sourceIndex: -1,
797797
target: {
798798
modelName: input.model.target,
799-
name: getLetter('Click ' + submit.text + ' ' + submit.label, input.operations.letter)
799+
name: getLetter('Click ' + getSanitizedText(submit.text) + ' ' +
800+
submit.label, input.operations.letter)
800801
},
801802
type: 'submit'
802803
};

0 commit comments

Comments
 (0)