This commit is contained in:
Cheng Zhao 2013-09-05 18:28:48 +08:00
Π ΠΎΠ΄ΠΈΡ‚Π΅Π»ΡŒ 6a322f8bd6
ΠšΠΎΠΌΠΌΠΈΡ‚ bc9c95d77d
1 ΠΈΠ·ΠΌΠ΅Π½Ρ‘Π½Π½Ρ‹Ρ… Ρ„Π°ΠΉΠ»ΠΎΠ²: 5 Π΄ΠΎΠ±Π°Π²Π»Π΅Π½ΠΈΠΉ ΠΈ 2 ΡƒΠ΄Π°Π»Π΅Π½ΠΈΠΉ

ΠŸΡ€ΠΎΡΠΌΠΎΡ‚Ρ€Π΅Ρ‚ΡŒ Ρ„Π°ΠΉΠ»

@ -114,8 +114,11 @@ describe 'protocol API', ->
free()
assert false, 'Got error: ' + errorType + ' ' + error
protocol.interceptProtocol targetScheme, (request) ->
pathInUrl = path.normalize request.url.substr(8)
assert.equal pathInUrl, __filename
if process.platform is 'win32'
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) ->
handler = remote.createFunctionWithReturnValue 'valar morghulis'