Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Side by Side Diff: trunk/src/third_party/JSON/JSON-2.59/t/e16_incr_parse_fixed.t

Issue 16539003: Revert 205057 "Add JSON.pm to third_party" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 #!/usr/bin/perl
2
3 BEGIN {
4 $ENV{ PERL_JSON_BACKEND } = $ARGV[0] || 'JSON::backportPP';
5 }
6
7 use strict;
8 use Test::More tests => 4;
9
10 use JSON;
11
12 my $json = JSON->new->allow_nonref();
13
14 my @vs = $json->incr_parse('"a\"bc');
15
16 ok( not scalar(@vs) );
17
18 @vs = $json->incr_parse('"');
19
20 is( $vs[0], "a\"bc" );
21
22
23 $json = JSON->new;
24
25 @vs = $json->incr_parse('"a\"bc');
26 ok( not scalar(@vs) );
27 @vs = eval { $json->incr_parse('"') };
28 ok($@ =~ qr/JSON text must be an object or array/);
29
OLDNEW
« no previous file with comments | « trunk/src/third_party/JSON/JSON-2.59/t/e15_tie_ixhash.t ('k') | trunk/src/third_party/JSON/JSON-2.59/t/e90_misc.t » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698