File: xe20_croak_message.t

package info (click to toggle)
libjson-perl 2.61-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 572 kB
  • ctags: 148
  • sloc: perl: 2,419; makefile: 2
file content (22 lines) | stat: -rw-r--r-- 394 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#! perl

# https://rt.cpan.org/Public/Bug/Display.html?id=61708

use strict;
use Test::More;

BEGIN { plan tests => 1 };
BEGIN { $ENV{PERL_JSON_BACKEND} = 1; }

use JSON; # currently it can't pass with -support_by_pp;


SKIP: {
    skip "can't use JSON::XS.", 1, unless( JSON->backend->is_xs );

    my $json = JSON->new;

    eval q{ $json->encode( undef ) };
    like( $@, qr/line 1\./ );
}