From: Shawn M Moore Date: Sun, 28 Sep 2008 19:30:21 +0000 (+0000) Subject: Tests for Mouse::Tiny + Mouse X-Git-Tag: 0.19~180 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=30f45363224c67f3801395c9a51319eac46228a6;p=gitmo%2FMouse.git Tests for Mouse::Tiny + Mouse --- diff --git a/t/600-tiny-tiny.t b/t/600-tiny-tiny.t new file mode 100644 index 0000000..c0b81f8 --- /dev/null +++ b/t/600-tiny-tiny.t @@ -0,0 +1,24 @@ +#!/usr/bin/env perl +use strict; +use warnings; +use Test::More tests => 2; + +do { + package Class; + use Mouse::Tiny; + + has attr => ( + is => 'rw', + ); + + package Class2; + use Mouse::Tiny; + + has attr => ( + is => 'rw', + ); +}; + +is(Class->new(attr => 'a')->attr, 'a'); +is(Class2->new(attr => 'b')->attr, 'b'); + diff --git a/t/601-tiny-mouse.t b/t/601-tiny-mouse.t new file mode 100644 index 0000000..2a61bf3 --- /dev/null +++ b/t/601-tiny-mouse.t @@ -0,0 +1,24 @@ +#!/usr/bin/env perl +use strict; +use warnings; +use Test::More tests => 2; + +do { + package Class; + use Mouse::Tiny; + + has attr => ( + is => 'rw', + ); + + package Class2; + use Mouse; + + has attr => ( + is => 'rw', + ); +}; + +is(Class->new(attr => 'a')->attr, 'a'); +is(Class2->new(attr => 'b')->attr, 'b'); + diff --git a/t/602-mouse-tiny.t b/t/602-mouse-tiny.t new file mode 100644 index 0000000..663d46c --- /dev/null +++ b/t/602-mouse-tiny.t @@ -0,0 +1,24 @@ +#!/usr/bin/env perl +use strict; +use warnings; +use Test::More tests => 2; + +do { + package Class; + use Mouse; + + has attr => ( + is => 'rw', + ); + + package Class2; + use Mouse::Tiny; + + has attr => ( + is => 'rw', + ); +}; + +is(Class->new(attr => 'a')->attr, 'a'); +is(Class2->new(attr => 'b')->attr, 'b'); +