From 278d188e58eebc70ce5d357d6c19e6cfbb978eb9 Mon Sep 17 00:00:00 2001 From: Sami Vaarala Date: Thu, 3 Jul 2014 21:44:41 +0300 Subject: [PATCH] API testcase fixes for updated error messages --- api-testcases/test-del-prop.c | 12 ++++++------ api-testcases/test-get-prop.c | 2 +- api-testcases/test-has-prop.c | 4 ++-- api-testcases/test-pcall-prop.c | 4 ++-- api-testcases/test-put-prop-primbase.c | 2 +- api-testcases/test-put-prop.c | 6 +++--- 6 files changed, 15 insertions(+), 15 deletions(-) diff --git a/api-testcases/test-del-prop.c b/api-testcases/test-del-prop.c index 0f5f3607..5bcabd2a 100644 --- a/api-testcases/test-del-prop.c +++ b/api-testcases/test-del-prop.c @@ -13,15 +13,15 @@ final array: ["foo","bar",null] final top: 3 ==> rc=0, result='undefined' *** test_1b (duk_pcall) -==> rc=1, result='TypeError: property not configurable' +==> rc=1, result='TypeError: not configurable' *** test_1c (duk_pcall) -==> rc=1, result='TypeError: property not configurable' +==> rc=1, result='TypeError: not configurable' *** test_1d (duk_safe_call) ==> rc=1, result='Error: invalid index' *** test_1e (duk_safe_call) ==> rc=1, result='Error: invalid index' *** test_1f (duk_safe_call) -==> rc=1, result='TypeError: invalid base reference for property delete' +==> rc=1, result='TypeError: invalid base value' *** test_2a (duk_safe_call) delete obj.foo -> rc=1 delete obj.nonexistent -> rc=1 @@ -36,9 +36,9 @@ final array: ["foo","bar",null] final top: 3 ==> rc=0, result='undefined' *** test_2b (duk_pcall) -==> rc=1, result='TypeError: property not configurable' +==> rc=1, result='TypeError: not configurable' *** test_2c (duk_pcall) -==> rc=1, result='TypeError: property not configurable' +==> rc=1, result='TypeError: not configurable' *** test_2d (duk_safe_call) ==> rc=1, result='Error: invalid index' *** test_2e (duk_safe_call) @@ -54,7 +54,7 @@ final array: ["foo","bar",null] final top: 3 ==> rc=0, result='undefined' *** test_3b (duk_pcall) -==> rc=1, result='TypeError: property not configurable' +==> rc=1, result='TypeError: not configurable' *** test_3c (duk_safe_call) ==> rc=1, result='Error: invalid index' *** test_3d (duk_safe_call) diff --git a/api-testcases/test-get-prop.c b/api-testcases/test-get-prop.c index 6051c4ef..4042f42c 100644 --- a/api-testcases/test-get-prop.c +++ b/api-testcases/test-get-prop.c @@ -20,7 +20,7 @@ configuration setting present, value: setting value final top: 4 ==> rc=0, result='undefined' *** test_1e (duk_safe_call) -==> rc=1, result='TypeError: invalid base reference for property read' +==> rc=1, result='TypeError: invalid base value' *** test_2a (duk_safe_call) obj.foo -> rc=1, result='fooval' obj.nonexistent -> rc=0, result='undefined' diff --git a/api-testcases/test-has-prop.c b/api-testcases/test-has-prop.c index 531250e6..b6ecad39 100644 --- a/api-testcases/test-has-prop.c +++ b/api-testcases/test-has-prop.c @@ -13,9 +13,9 @@ final top: 3 *** test_1c (duk_safe_call) ==> rc=1, result='Error: invalid index' *** test_1d (duk_safe_call) -==> rc=1, result='TypeError: invalid base reference for property existence check' +==> rc=1, result='TypeError: invalid base value' *** test_1e (duk_safe_call) -==> rc=1, result='TypeError: invalid base reference for property existence check' +==> rc=1, result='TypeError: invalid base value' *** test_2a (duk_safe_call) obj.foo -> rc=1 obj.nonexistent -> rc=0 diff --git a/api-testcases/test-pcall-prop.c b/api-testcases/test-pcall-prop.c index 5f3d582d..15766318 100644 --- a/api-testcases/test-pcall-prop.c +++ b/api-testcases/test-pcall-prop.c @@ -15,7 +15,7 @@ rc=0, result='21' rc=1, result='Error: my error' ==> rc=0, result='undefined' *** test_5 (duk_safe_call) -rc=1, result='TypeError: invalid base reference for property read' +rc=1, result='TypeError: invalid base value' ==> rc=0, result='undefined' *** test_6 (duk_safe_call) rc=1, result='RangeError: getter error' @@ -24,7 +24,7 @@ rc=1, result='RangeError: getter error' rc=1, result='Error: invalid index' ==> rc=0, result='undefined' *** test_8 (duk_safe_call) -rc=1, result='TypeError: call target not callable' +rc=1, result='TypeError: not callable' ==> rc=0, result='undefined' *** test_9 (duk_safe_call) ==> rc=1, result='Error: invalid call args' diff --git a/api-testcases/test-put-prop-primbase.c b/api-testcases/test-put-prop-primbase.c index 11b7efb0..f048f663 100644 --- a/api-testcases/test-put-prop-primbase.c +++ b/api-testcases/test-put-prop-primbase.c @@ -4,7 +4,7 @@ put rc=0 final top: 1 ==> rc=0, result='undefined' *** test_put (duk_pcall) -==> rc=1, result='TypeError: non-object base reference' +==> rc=1, result='TypeError: invalid base value' ===*/ int test_put(duk_context *ctx) { diff --git a/api-testcases/test-put-prop.c b/api-testcases/test-put-prop.c index e4f76d43..30b669c1 100644 --- a/api-testcases/test-put-prop.c +++ b/api-testcases/test-put-prop.c @@ -23,7 +23,7 @@ final top: 2 strict: 1 get Math -> rc=1 Math.PI=3.141592653589793 -==> rc=1, result='TypeError: property not writable' +==> rc=1, result='TypeError: not writable' *** test_ex_accessor_wo_setter (duk_safe_call) strict: 0 eval: @@ -56,7 +56,7 @@ eval: return o; })() top after eval: 1 -==> rc=1, result='TypeError: undefined setter for accessor' +==> rc=1, result='TypeError: setter undefined' *** test_ex_setter_throws (duk_safe_call) strict: 0 eval: @@ -115,7 +115,7 @@ strict: 1 eval: (function () { var o = { foo: 1 }; Object.preventExtensions(o); return o; })() top after eval: 1 -==> rc=1, result='TypeError: object not extensible' +==> rc=1, result='TypeError: not extensible' ===*/ /* Test property writing API call.