File tree Expand file tree Collapse file tree
javascript/node/selenium-webdriver Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -162,5 +162,5 @@ module.exports = {
162162 Command,
163163 Options,
164164 Result,
165- exec
165+ exec,
166166}
Original file line number Diff line number Diff line change @@ -56,11 +56,11 @@ let Server = function (requestHandler) {
5656 typeof opt_port !== 'function' ,
5757 'start invoked with function, not port (mocha callback)?'
5858 )
59- const port = opt_port || portprober . findFreePort ( 'localhost ' )
59+ const port = opt_port || portprober . findFreePort ( '127.0.0.1 ' )
6060 return Promise . resolve ( port )
6161 . then ( ( port ) => {
6262 return promise . checkedNodeCall (
63- server . listen . bind ( server , port , 'localhost ' )
63+ server . listen . bind ( server , port , '127.0.0.1 ' )
6464 )
6565 } )
6666 . then ( function ( ) {
Original file line number Diff line number Diff line change @@ -76,11 +76,7 @@ function getAddress(family = 'IPv4') {
7676 * @return {(string|undefined) } The IP address or undefined if not available.
7777 */
7878function getLoopbackAddress ( family = 'IPv4' ) {
79- let address = getIPAddress ( true , family )
80- if ( address === '127.0.0.1' ) {
81- address = 'localhost'
82- }
83- return address
79+ return getIPAddress ( true , family )
8480}
8581
8682/**
Original file line number Diff line number Diff line change @@ -136,7 +136,9 @@ suite(function (env) {
136136
137137 beforeEach ( async function ( ) {
138138 driver = await env . builder ( ) . build ( )
139- await driver . get ( fileServer . Pages . virtualAuthenticator )
139+ await driver . get (
140+ fileServer . Pages . virtualAuthenticator . replace ( '127.0.0.1' , 'localhost' )
141+ )
140142 assert . strictEqual ( await driver . getTitle ( ) , 'Virtual Authenticator Tests' )
141143 } )
142144
Original file line number Diff line number Diff line change @@ -52,7 +52,9 @@ test.suite(function (env) {
5252 it ( 'can set size of the current window from iframe' , async function ( ) {
5353 await driver . get ( test . Pages . iframePage )
5454
55- const frame = await driver . findElement ( { css : 'iframe[name="iframe1-name"]' } )
55+ const frame = await driver . findElement ( {
56+ css : 'iframe[name="iframe1-name"]' ,
57+ } )
5658 await driver . switchTo ( ) . frame ( frame )
5759 await changeSizeBy ( - 20 , - 20 )
5860 } )
You can’t perform that action at this time.
0 commit comments