Fix protocol spec on Windows.

This commit is contained in:
Cheng Zhao 2013-12-17 23:03:36 +08:00
parent c04a9933cc
commit d8eb465eb9

View file

@ -116,7 +116,7 @@ describe 'protocol module', ->
protocol.interceptProtocol targetScheme, (request) -> protocol.interceptProtocol targetScheme, (request) ->
if process.platform is 'win32' if process.platform is 'win32'
pathInUrl = path.normalize request.url.substr(8) pathInUrl = path.normalize request.url.substr(8)
assert.equal pathInUrl, __filename assert.equal pathInUrl.toLowerCase(), __filename.toLowerCase()
else else
assert.equal request.url, "#{targetScheme}://#{__filename}" assert.equal request.url, "#{targetScheme}://#{__filename}"