Skip to content

Commit c4e313f

Browse files
committed
Fixed tests for some phantomjs bug
1 parent af46d42 commit c4e313f

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

tests/AllTests.js

100644100755
Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1011,7 +1011,19 @@ class AllTests
10111011
}
10121012
);
10131013

1014-
const phantomPage = await phantom.createPage();
1014+
try
1015+
{
1016+
const phantomPage = await phantom.createPage();
1017+
}
1018+
catch(error)
1019+
{
1020+
if(error.message.includes("Error reading from stdin"))
1021+
{
1022+
// https://github.com/amir20/phantomjs-node/issues/649
1023+
return;
1024+
}
1025+
}
1026+
10151027
await phantomPage.setting("javascriptEnabled", true);
10161028

10171029

0 commit comments

Comments
 (0)