Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
1 // Any copyright is dedicated to the Public Domain.
2 // http://creativecommons.org/licenses/publicdomain/
4 testJSON('[', true);
5 testJSON('[1', true);
6 testJSON('[1,]', true);
7 testJSON('[1,{', true);
8 testJSON('[1,}', true);
9 testJSON('[1,{]', true);
10 testJSON('[1,}]', true);
11 testJSON('[1,{"', true);
12 testJSON('[1,}"', true);
13 testJSON('[1,{"\\', true);
14 testJSON('[1,}"\\', true);
15 testJSON('[1,"', true);
16 testJSON('[1,"\\', true);
18 testJSON('{', true);
19 testJSON('{1', true);
20 testJSON('{,', true);
21 testJSON('{"', true);
22 testJSON('{"\\', true);
23 testJSON('{"\\u', true);
24 testJSON('{"\\uG', true);
25 testJSON('{"\\u0', true);
26 testJSON('{"\\u01', true);
27 testJSON('{"\\u012', true);
28 testJSON('{"\\u0123', true);
29 testJSON('{"\\u0123"', true);
30 testJSON('{"a"', true);
31 testJSON('{"a"}', true);
32 testJSON('{"a":', true);
33 testJSON('{"a",}', true);
34 testJSON('{"a":}', true);
35 testJSON('{"a":,}', true);
36 testJSON('{"a":5,}', true);
37 testJSON('{"a":5,[', true);
38 testJSON('{"a":5,"', true);
39 testJSON('{"a":5,"', true);
40 testJSON('{"a":5,"\\', true);
41 testJSON("a[false ]".substring(1, 7) /* "[false" */, true);
43 testJSON('this', true);
45 testJSON('[1,{}]', false);
46 testJSON('{}', false);
47 testJSON('{"a":5}', false);
48 testJSON('{"\\u0123":5}', false);
50 /******************************************************************************/
52 if (typeof reportCompare === "function")
53 reportCompare(true, true);
55 print("Tests complete");