Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
John McEleney
/
casperjs
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
c46f69c0
...
c46f69c07cf61995496d8fe4a4f1005d204e9fc9
authored
2014-02-17 16:35:45 +0100
by
Nicolas Perriault
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fixed possible intermittent failure in form filling tests
1 parent
08c2c710
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
7 deletions
tests/suites/casper/formfill.js
tests/suites/casper/formfill.js
View file @
c46f69c
...
...
@@ -125,14 +125,12 @@ casper.test.begin('nonexistent fields', 1, function(test) {
});
});
casper
.
test
.
begin
(
'multiple forms'
,
2
,
function
(
test
)
{
casper
.
test
.
begin
(
'multiple forms'
,
1
,
function
(
test
)
{
casper
.
start
(
'tests/site/multiple-forms.html'
,
function
()
{
this
.
fill
(
'form[name="f2"]'
,
{
yo
:
"ok"
},
true
);
}).
then
(
function
()
{
test
.
assertUrlMatch
(
/
\?
f=f2&yo=ok$/
,
'Casper.fill() handles multiple forms'
);
}).
then
(
function
()
{
}).
waitForUrl
(
/
\?
f=f2&yo=ok$/
,
function
()
{
this
.
fill
(
'form[name="f2"]'
,
{
yo
:
"ok"
});
...
...
@@ -152,9 +150,8 @@ casper.test.begin('field array', 1, function(test) {
'foo[bar]'
:
"bar"
,
'foo[baz]'
:
"baz"
},
true
);
}).
then
(
function
()
{
test
.
assertUrlMatch
(
'?foo[bar]=bar&foo[baz]=baz'
,
'Casper.fill() handles array syntax field names'
);
}).
waitForUrl
(
"?foo[bar]=bar&foo[baz]=baz"
,
function
()
{
test
.
pass
(
'Casper.fill() handles array syntax field names'
);
}).
run
(
function
()
{
test
.
done
();
});
...
...
Please
register
or
sign in
to post a comment