💄 fix the protocol module spec on OS X.
This commit is contained in:
parent
6a322f8bd6
commit
bc9c95d77d
1 changed files with 5 additions and 2 deletions
|
@ -114,8 +114,11 @@ describe 'protocol API', ->
|
||||||
free()
|
free()
|
||||||
assert false, 'Got error: ' + errorType + ' ' + error
|
assert false, 'Got error: ' + errorType + ' ' + error
|
||||||
protocol.interceptProtocol targetScheme, (request) ->
|
protocol.interceptProtocol targetScheme, (request) ->
|
||||||
pathInUrl = path.normalize request.url.substr(8)
|
if process.platform is 'win32'
|
||||||
assert.equal pathInUrl, __filename
|
pathInUrl = path.normalize request.url.substr(8)
|
||||||
|
assert.equal pathInUrl, __filename
|
||||||
|
else
|
||||||
|
assert.equal request.url, "#{targetScheme}://#{__filename}"
|
||||||
|
|
||||||
it 'can override original protocol handler', (done) ->
|
it 'can override original protocol handler', (done) ->
|
||||||
handler = remote.createFunctionWithReturnValue 'valar morghulis'
|
handler = remote.createFunctionWithReturnValue 'valar morghulis'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue