summaryrefslogtreecommitdiff
path: root/lib/perl5db
diff options
context:
space:
mode:
authorShlomi Fish <shlomif@shlomifish.org>2012-09-15 17:10:13 +0300
committerRicardo Signes <rjbs@cpan.org>2012-11-12 09:18:23 -0500
commitfedbbdd550d46ec802d1103f46e6f1e8a524df57 (patch)
treed76d9dac1e2fe9b093a4ce044e810a66b09ae420 /lib/perl5db
parent12f1669fbe98ce0d45bdc40a065632c53dc919a6 (diff)
downloadperl-fedbbdd550d46ec802d1103f46e6f1e8a524df57.tar.gz
Test more for the m staetement.
Diffstat (limited to 'lib/perl5db')
-rw-r--r--lib/perl5db/t/test-m-statement-143
1 files changed, 43 insertions, 0 deletions
diff --git a/lib/perl5db/t/test-m-statement-1 b/lib/perl5db/t/test-m-statement-1
new file mode 100644
index 0000000000..a699ed342e
--- /dev/null
+++ b/lib/perl5db/t/test-m-statement-1
@@ -0,0 +1,43 @@
+use strict;
+use warnings;
+
+package MyClass;
+
+sub new
+{
+ my $class = shift;
+
+ my $self = bless {}, $class;
+
+ $self->_init(@_);
+
+ return $self;
+}
+
+sub _init
+{
+ my $self = shift;
+
+ $self->{foo} = 'bar';
+
+ return;
+}
+
+sub greet
+{
+ my ($self, $msg) = @_;
+
+ print "$msg - $self->{foo}\n";
+
+ return;
+}
+
+1;
+
+package main;
+
+my $obj = MyClass->new;
+
+$obj->greet("Hello");
+
+1;