[Rt-commit] [svn] r989 - in experiments/Bamboo: . t
jesse at pallas.eruditorum.org
jesse at pallas.eruditorum.org
Mon May 31 23:09:32 EDT 2004
Author: jesse
Date: Mon May 31 23:09:32 2004
New Revision: 989
Added:
experiments/Bamboo/t/2model.t
Modified:
experiments/Bamboo/ (props changed)
Log:
----------------------------------------------------------------------
r1748 at debian: jesse | 2004-06-01T12:13:16.226636Z
starting to play with a Class::Meta model
----------------------------------------------------------------------
Added: experiments/Bamboo/t/2model.t
==============================================================================
--- (empty file)
+++ experiments/Bamboo/t/2model.t Mon May 31 23:09:32 2004
@@ -0,0 +1,22 @@
+package Bamboo::MockTicket;
+
+use strict;
+use Class::Meta;
+use Class::Meta::Types::String;
+
+BEGIN {
+my $cm = Class::Meta->new();
+$cm->add_constructor( name => 'new',
+ create => 1);
+
+$cm->add_attribute( name => 'Status', type => 'string');
+$cm->build();
+}
+
+package main;
+
+use Test::More qw/no_plan/;
+my $mockticket = Bamboo::MockTicket->new();
+is(ref($mockticket),'Bamboo::MockTicket');
+$mockticket->Status('new');
+is ($mockticket->Status, 'new');
More information about the Rt-commit
mailing list