From 2d1fa15826038af4b1f4ba6cbe78b5a68a535add Mon Sep 17 00:00:00 2001 From: Ian Young Date: Thu, 5 Apr 2012 15:11:30 -0700 Subject: [PATCH] Bring back tests for Image --- spec/script_spec.coffee | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/spec/script_spec.coffee b/spec/script_spec.coffee index c447a1cd3..008fef40f 100644 --- a/spec/script_spec.coffee +++ b/spec/script_spec.coffee @@ -317,15 +317,13 @@ Vows.describe("Scripts").addBatch "should run scripts with file url src": (browser)-> assert.equal browser.document.title, "file://" - ### .addBatch "new Image": Browser.wants "http://localhost:3003/script/living" - "should construct an img tag": (browser)-> assert.equal domToHtml(browser.evaluate("new Image")), "\r\n" + "should construct an img tag": (browser)-> + assert.equal browser.evaluate("new Image").tagName, "IMG" "should construct an img tag with width and height": (browser)-> - assert.equal domToHtml(browser.evaluate("new Image(1, 1)")), "\r\n" - ### + assert.equal browser.evaluate("new Image(1, 1)").height, 1 - .export(module)