1 ################################################################################
3 # !!!!! Do NOT edit this file directly! !!!!!
5 # Edit mktests.PL and/or parts/inc/sv_xpvf instead.
7 ################################################################################
10 if ($ENV{'PERL_CORE'}) {
12 @INC = ('../lib', '../ext/Devel/PPPort/t') if -d '../lib' && -d '../ext';
13 require Config; import Config;
15 if (" $Config{'extensions'} " !~ m[ Devel/PPPort ] ) {
16 print "1..0 # Skip -- Perl configured without Devel::PPPort module\n";
26 require 'testutil.pl';
40 tie %h, 'Tie::StdHash';
44 ok(&Devel::PPPort::vnewSVpvf(), $] >= 5.004 ? 'Perl-42' : '%s-%d');
45 ok(&Devel::PPPort::sv_vcatpvf('1-2-3-'), $] >= 5.004 ? '1-2-3-Perl-42' : '1-2-3-%s-%d');
46 ok(&Devel::PPPort::sv_vsetpvf('1-2-3-'), $] >= 5.004 ? 'Perl-42' : '%s-%d');
48 &Devel::PPPort::sv_catpvf_mg($h{foo});
49 ok($h{foo}, $] >= 5.004 ? 'foo-Perl-42' : 'foo-');
51 &Devel::PPPort::Perl_sv_catpvf_mg($h{foo});
52 ok($h{foo}, $] >= 5.004 ? 'foo-Perl-42-Perl-43' : 'foo-');
54 &Devel::PPPort::sv_catpvf_mg_nocontext($h{foo});
55 ok($h{foo}, $] >= 5.004 ? 'foo-Perl-42-Perl-43-Perl-44' : 'foo-');
57 &Devel::PPPort::sv_setpvf_mg($h{bar});
58 ok($h{bar}, $] >= 5.004 ? 'mhx-42' : '');
60 &Devel::PPPort::Perl_sv_setpvf_mg($h{bar});
61 ok($h{bar}, $] >= 5.004 ? 'foo-43' : '');
63 &Devel::PPPort::sv_setpvf_mg_nocontext($h{bar});
64 ok($h{bar}, $] >= 5.004 ? 'bar-44' : '');