Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Testing -- making a new constructor behave differently for one package

by tj_thompson (Monk)
on Jan 27, 2012 at 22:25 UTC ( [id://950458]=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    # added some debug output
    *DB::Handle::RapTTR::Test::real_new = \&DB::Handle::RapTTR::Test::new;
    *DB::Handle::RapTTR::Test::new =
    ...
              password => undef
          );
      };
    
  2. or download this
    TRACE: at t/comprehensive_3digbn_8digtid.t line 54
            main::__ANON__('DB::Handle::RapTTR::Test') called at t/compreh
    +ensive_3digbn_8digtid.t line 50
            main::__ANON__('DB::Handle::RapTTR::Test') called at /nfs/pdx/
    +disks/nehalem.pde.077/projects/2.0_rapttr/RapTTR/blib/lib/RapTTR.pm l
    +ine 688
    ...
            RapTTR::harness('RapTTR=HASH(0x26931a0)') called at t/comprehe
    +nsive_3digbn_8digtid.t line 63
    # Looks like you planned 24 tests but ran 2.
    # Looks like your test exited with 2 just after 2.
    
  3. or download this
    prepare failed with DBI error (1):no such table: pcf_master
     at /nfs/pdx/disks/nehalem.pde.077/perl/5.12.2/lib64/site_perl/DB/SQL/
    +Query.pm line 114
    
  4. or download this
    main::__ANON__('DB::Handle::RapTTR::Test') called at t/comprehensive_3
    +digbn_8digtid.t line 50
            main::__ANON__('DB::Handle::RapTTR::Test') called at /nfs/pdx/
    +disks/nehalem.pde.077/projects/2.0_rapttr/RapTTR/blib/lib/RapTTR.pm l
    +ine 688
    
  5. or download this
    use strict;
    use warnings;
    
    ...
    I am bar from Foo.
     # output from original sub after being redefined back
    I am bar from Foo.
    
  6. or download this
    #! /usr/intel/pkgs/perl/5.12.2/bin/perl
    use strict;
    use warnings;
    ...
    
    $obj = Foo->new;
    print STDERR __PACKAGE__.": FOO IS (".ref($obj).")\n";
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://950458]
Approved by planetscape
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (3)
As of 2024-04-19 01:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found