Implement DDisplay ()
[Data-Peek.git] / t / 21_DDisplay.t
blob30776047f36ea5f9a5861222aa395f686724038b
1 #!/usr/bin/perl
3 use strict;
4 use warnings;
6 use Test::More tests => 9;
8 use Data::Peek;
10 is (DDisplay (undef), '', 'undef has no PV');
11 is (DDisplay (0), '', '0 has no PV');
12 is (DDisplay (\undef), '', '\undef has no PV');
13 is (DDisplay (\0), '', '\0 has no PV');
14 is (DDisplay (sub {}), '', 'code has no PV');
16 is (DDisplay (""), '""', 'empty string');
17 is (DDisplay ("a"), '"a"', '"a"');
18 is (DDisplay ("\n"), '"\n"', '"\n"');
19 is (DDisplay ("\x{20ac}"), '"\x{20ac}"', '"\n"');