| Index: LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
|
| diff --git a/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js b/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
|
| index 1344e634df43ac036d8f762ff9ab83096c6e85c0..c6b78659b52c21841a2de725c1939593c6dac2d7 100644
|
| --- a/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
|
| +++ b/LayoutTests/fast/canvas/script-tests/canvas-overloads-fillText.js
|
| @@ -2,12 +2,15 @@ description("Test the behavior of CanvasRenderingContext2D.fillText() when calle
|
|
|
| var ctx = document.createElement('canvas').getContext('2d');
|
|
|
| -var NotEnoughArguments = "TypeError: Not enough arguments";
|
| +function ExpectedNotEnoughArgumentsMessage(num) {
|
| + return "\"TypeError: Failed to execute 'fillText' on 'CanvasRenderingContext2D': 3 arguments required, but only " + num + " present.\"";
|
| +}
|
| +
|
| var TypeError = "TypeError: Type error";
|
|
|
| -shouldThrow("ctx.fillText()", "NotEnoughArguments");
|
| -shouldThrow("ctx.fillText('moo')", "NotEnoughArguments");
|
| -shouldThrow("ctx.fillText('moo',0)", "NotEnoughArguments");
|
| +shouldThrow("ctx.fillText()", ExpectedNotEnoughArgumentsMessage(0));
|
| +shouldThrow("ctx.fillText('moo')", ExpectedNotEnoughArgumentsMessage(1));
|
| +shouldThrow("ctx.fillText('moo',0)", ExpectedNotEnoughArgumentsMessage(2));
|
| shouldBe("ctx.fillText('moo',0,0)", "undefined");
|
| shouldBe("ctx.fillText('moo',0,0,0)", "undefined");
|
| shouldBe("ctx.fillText('moo',0,0,0,0)", "undefined");
|
|
|