From d3dd7c7dcdd4e7d1f01aab62f9ef87660329b015 Mon Sep 17 00:00:00 2001 From: dhrname Date: Sun, 15 Sep 2013 23:49:33 +0900 Subject: [PATCH] =?utf8?q?open=E3=83=A1=E3=82=BD=E3=83=83=E3=83=89?= =?utf8?q?=E3=81=AB=E3=83=A1=E3=82=BD=E3=83=83=E3=83=89=E3=83=81=E3=82=A7?= =?utf8?q?=E3=83=BC=E3=83=B3=E3=82=92=E5=AE=9F=E8=A3=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- tool/funcproto/openfile.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tool/funcproto/openfile.js b/tool/funcproto/openfile.js index 4b85b5d..f92f67f 100644 --- a/tool/funcproto/openfile.js +++ b/tool/funcproto/openfile.js @@ -41,6 +41,7 @@ Function.prototype.open = function() { xhr.send(null); }; f(); + return this; }; Function.empty = function(){}; @@ -60,6 +61,10 @@ function f (file) { expect(file[4]).toEqual("5678"); expect(file.write("30d")).toEqual("30d"); }); + it("default property", function() { + var f = function() {}; + expect(f.open("")).toEqual(f); + }); }); __start_(); }; \ No newline at end of file -- 2.11.0