X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-json_post;a=blobdiff_plain;f=tests%2Ferror002.phpt;h=076d2a71edefcf435eb1f520323981e8f3f9b274;hp=3903d23df5dcaee62e9977051eaa03e4edd66a8f;hb=c1b0270e93fc2706027296233553933d03d3fd1e;hpb=98b35c8f1a7c1c1bc818ee163048a76c81dd7141 diff --git a/tests/error002.phpt b/tests/error002.phpt index 3903d23..076d2a7 100644 --- a/tests/error002.phpt +++ b/tests/error002.phpt @@ -1,30 +1,14 @@ --TEST-- -json_post with malformed JSON (https://github.com/m6w6/ext-json_post/issues/3) ---SKIPIF-- - +json_post with malformed JSON [response] (https://github.com/m6w6/ext-json_post/issues/3) --INI-- -json_post.error_response = 400 -json_post.flags = 4194305 +json_post.onerror.response = 400 --POST_RAW-- Content-Type: application/json -{ - "greeting": "Hello World -} ---FILE-- - -Done +{"a +--FILE_EXTERNAL-- +error.inc --EXPECTHEADERS-- Status: 400 Bad Request -X-JSON-Error-Code: 3 ---EXPECTF-- -array(0) { -} -int(400) -Done +--EXPECT-- +DONE