Help for this page

Select Code to Download


  1. or download this
    use warnings;
    use strict;
    ...
    }
    
    my $foo_sub = $m->mock('foo');
    
  2. or download this
    Prototype mismatch: sub main::foo ($$$) vs none at /home/stevieb/perl5
    +/perlbrew/perls/perl-5.26.1/lib/site_perl/5.26.1/Mock/Sub/Child.pm li
    +ne 122.
    Prototype mismatch: sub main::foo: none vs ($$$) at /home/stevieb/perl
    +5/perlbrew/perls/perl-5.26.1/lib/site_perl/5.26.1/Mock/Sub/Child.pm l
    +ine 140.
    
  3. or download this
    use warnings;
    use strict;
    ...
    say foo(1, 2, 3);
    
    say $foo->called_count;
    
  4. or download this
    test
    test
    test
    3
    
  5. or download this
    Not enough arguments for main::foo at mock.pl line 21, near "()"
    Execution of mock.pl aborted due to compilation errors.
    
  6. or download this
        {
            no strict 'refs';
    ...
                }
            };
        }