From: Cheng Zhao Date: Thu, 29 Aug 2013 10:03:14 +0000 (+0800) Subject: :lipstick: Avoid duplicate temporary file names. X-Git-Tag: v0.4.2~5 X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=efd2bbbede90c4667a1eb219f6c05940969e8f1b;p=electron.git :lipstick: Avoid duplicate temporary file names. --- diff --git a/spec/api/window.coffee b/spec/api/window.coffee index cd832e96..d4a4b79f 100644 --- a/spec/api/window.coffee +++ b/spec/api/window.coffee @@ -14,7 +14,7 @@ describe 'window module', -> if (!isLoading) w.close() w.on 'destroyed', -> - test = path.join(fixtures, 'api', 'test') + test = path.join(fixtures, 'api', 'unload') content = fs.readFileSync(test) fs.unlinkSync(test) assert.equal String(content), 'unload' @@ -41,8 +41,10 @@ describe 'window module', -> assert.equal isLoading, true else if count == 1 assert.equal isLoading, false + w.close() done() else + w.close() assert false ++count diff --git a/spec/fixtures/api/close.html b/spec/fixtures/api/close.html index 0b6e4f36..24846f72 100644 --- a/spec/fixtures/api/close.html +++ b/spec/fixtures/api/close.html @@ -2,7 +2,7 @@ diff --git a/spec/fixtures/api/unload.html b/spec/fixtures/api/unload.html index 9490c56d..da749641 100644 --- a/spec/fixtures/api/unload.html +++ b/spec/fixtures/api/unload.html @@ -2,7 +2,7 @@