1# copied over from JSON::XS and modified to use JSON::PP 2 3# adapted from a test by Martin Evans 4 5use strict; 6use warnings; 7 8BEGIN { $ENV{PERL_JSON_BACKEND} = 0; } 9 10use JSON::PP; 11 12print "1..1\n"; 13 14my $data = ["\x{53f0}\x{6240}\x{306e}\x{6d41}\x{3057}", 15 "\x{6c60}\x{306e}\x{30ab}\x{30a8}\x{30eb}"]; 16my $js = JSON::PP->new->encode ($data); 17my $j = JSON::PP->new; 18my $object = $j->incr_parse ($js); 19 20die "no object" if !$object; 21 22eval { $j->incr_text }; 23 24print $@ ? "not " : "", "ok 1 # $@\n"; 25 26