summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/canvas/script-tests
diff options
context:
space:
mode:
authorabarth@webkit.org <abarth@webkit.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2011-06-20 23:54:07 +0000
committerabarth@webkit.org <abarth@webkit.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2011-06-20 23:54:07 +0000
commitd633387a5b474d27289aa6df3555cef776462045 (patch)
tree16bf06501a295848b2c5f905f45e4af490751c47 /third_party/WebKit/LayoutTests/fast/canvas/script-tests
parent81efb9e6a550269051534932edbbf70e06b4cdbe (diff)
downloadchromium_src-d633387a5b474d27289aa6df3555cef776462045.zip
chromium_src-d633387a5b474d27289aa6df3555cef776462045.tar.gz
chromium_src-d633387a5b474d27289aa6df3555cef776462045.tar.bz2
2011-06-20 Mark Pilgrim <pilgrim@chromium.org>
Reviewed by Adam Barth. IDL generator should throw TypeError instead of SyntaxError on not enough arguments https://bugs.webkit.org/show_bug.cgi?id=63011 To align with WebIDL, we should throw TypeError whenever a function is called with missing required arguments. * fast/canvas/canvas-overloads-drawImageFromRect-expected.txt: * fast/canvas/canvas-overloads-fillText-expected.txt: * fast/canvas/canvas-overloads-strokeText-expected.txt: * fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js: * fast/canvas/script-tests/canvas-overloads-fillText.js: * fast/canvas/script-tests/canvas-overloads-strokeText.js: * fast/canvas/webgl/data-view-test-expected.txt: * http/tests/xmlhttprequest/exceptions-expected.txt: * platform/chromium-mac/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt: * platform/chromium-win/svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt: * svg/dom/SVGAngle-expected.txt: * svg/dom/SVGColor-expected.txt: * svg/dom/SVGLength-expected.txt: * svg/dom/SVGLengthList-basics-expected.txt: * svg/dom/SVGMatrix-expected.txt: * svg/dom/SVGNumberList-basics-expected.txt: * svg/dom/SVGPaint-expected.txt: * svg/dom/SVGPoint-expected.txt: * svg/dom/SVGPointList-basics-expected.txt: * svg/dom/SVGStringList-basics-expected.txt: * svg/dom/SVGTransform-expected.txt: * svg/dom/SVGTransformList-basics-expected.txt: * svg/dom/SVGTransformList-expected.txt: * svg/dom/svgpath-out-of-bounds-getPathSeg-expected.txt: 2011-06-20 Mark Pilgrim <pilgrim@chromium.org> Reviewed by Adam Barth. IDL generator should throw TypeError instead of SyntaxError on not enough arguments https://bugs.webkit.org/show_bug.cgi?id=63011 To align with WebIDL, we should throw TypeError whenever a function is called with missing required arguments. * bindings/scripts/CodeGeneratorJS.pm: * bindings/scripts/CodeGeneratorV8.pm: * bindings/scripts/test/V8/V8TestObj.cpp: (WebCore::TestObjInternal::methodThatRequiresAllArgsAndThrowsCallback): git-svn-id: svn://svn.chromium.org/blink/trunk@89315 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Diffstat (limited to 'third_party/WebKit/LayoutTests/fast/canvas/script-tests')
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js4
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js8
-rw-r--r--third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js8
3 files changed, 10 insertions, 10 deletions
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js
index a32c8c5..dbc7edd 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js
+++ b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-drawImageFromRect.js
@@ -2,10 +2,10 @@ description("Test the behavior of CanvasRenderingContext2D.drawImageFromRect() w
var ctx = document.createElement('canvas').getContext('2d');
-var SyntaxError = "SyntaxError: Not enough arguments";
+var NotEnoughArguments = "TypeError: Not enough arguments";
var imageElement = document.createElement("img");
-shouldThrow("ctx.drawImageFromRect()", "SyntaxError");
+shouldThrow("ctx.drawImageFromRect()", "NotEnoughArguments");
shouldBe("ctx.drawImageFromRect(imageElement)", "undefined");
shouldBe("ctx.drawImageFromRect(imageElement, 0)", "undefined");
shouldBe("ctx.drawImageFromRect(imageElement, 0, 0)", "undefined");
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
index 5429d3f..6597e18 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
+++ b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
@@ -2,12 +2,12 @@ description("Test the behavior of CanvasRenderingContext2D.fillText() when calle
var ctx = document.createElement('canvas').getContext('2d');
-var SyntaxError = "SyntaxError: Not enough arguments";
+var NotEnoughArguments = "TypeError: Not enough arguments";
var TypeError = "TypeError: Type error";
-shouldThrow("ctx.fillText()", "SyntaxError");
-shouldThrow("ctx.fillText('moo')", "SyntaxError");
-shouldThrow("ctx.fillText('moo',0)", "SyntaxError");
+shouldThrow("ctx.fillText()", "NotEnoughArguments");
+shouldThrow("ctx.fillText('moo')", "NotEnoughArguments");
+shouldThrow("ctx.fillText('moo',0)", "NotEnoughArguments");
shouldBe("ctx.fillText('moo',0,0)", "undefined");
shouldBe("ctx.fillText('moo',0,0,0)", "undefined");
shouldBe("ctx.fillText('moo',0,0,0,0)", "undefined");
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js
index 8cc9729..8a9079f 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js
+++ b/third_party/WebKit/LayoutTests/fast/canvas/script-tests/canvas-overloads-strokeText.js
@@ -2,11 +2,11 @@ description("Test the behavior of CanvasRenderingContext2D.strokeText() when cal
var ctx = document.createElement('canvas').getContext('2d');
-var SyntaxError = "SyntaxError: Not enough arguments";
+var NotEnoughArguments = "TypeError: Not enough arguments";
-shouldThrow("ctx.strokeText()", "SyntaxError");
-shouldThrow("ctx.strokeText('moo')", "SyntaxError");
-shouldThrow("ctx.strokeText('moo',0)", "SyntaxError");
+shouldThrow("ctx.strokeText()", "NotEnoughArguments");
+shouldThrow("ctx.strokeText('moo')", "NotEnoughArguments");
+shouldThrow("ctx.strokeText('moo',0)", "NotEnoughArguments");
shouldBe("ctx.strokeText('moo',0,0)", "undefined");
shouldBe("ctx.strokeText('moo',0,0,0)", "undefined");
shouldBe("ctx.strokeText('moo',0,0,0,0)", "undefined");