Permalink
Browse files

v0.015

	* NO CODE CHANGES from 0.014.  We should be at a good point where the
	  newer attribute checking tests are useable and won't need to change in
	  any incompatible ways (hopefully!).
  • Loading branch information...
1 parent 67e5da0 commit 8c8bdcdd6388bbab63046a353698815aac163384 @RsrchBoy committed Oct 21, 2012
Showing with 43 additions and 5 deletions.
  1. +5 −0 Changes
  2. +38 −5 README.pod
View
@@ -2,6 +2,11 @@ Revision history for Test-Moose-More
{{$NEXT}}
+0.015 2012-10-20 17:00:59 PST8PDT
+ * NO CODE CHANGES from 0.014. We should be at a good point where the
+ newer attribute checking tests are useable and won't need to change in
+ any incompatible ways (hopefully!).
+
0.014 2012-10-04 20:28:49 PST8PDT
* TRIAL release
* better tests for our new validate_attribute and attribute_options_ok
View
@@ -10,7 +10,7 @@ Test::Moose::More - More tools for testing Moose packages
=head1 VERSION
-This document describes version 0.014 of Test::Moose::More - released October 04, 2012 as part of Test-Moose-More.
+This document describes version 0.015 of Test::Moose::More - released October 20, 2012 as part of Test-Moose-More.
=head1 SYNOPSIS
@@ -128,17 +128,50 @@ additional class-specific tests.
=head2 validate_attribute
-Run checks against an attribute.
+validate_attribute() allows you to test how an attribute looks once built and
+attached to a class.
+
+Let's say you have an attribute defined like this:
+
+ has foo => (
+ traits => [ 'TestRole' ],
+ is => 'ro',
+ isa => 'Int',
+ builder => '_build_foo',
+ lazy => 1,
+ );
+
+You can use validate_attribute() to ensure that it's built out in the way you
+expect:
+
+ validate_attribute TestClass => foo => (
+ -does => [ 'TestRole' ],
+ -isa => [ 'Moose::Meta::Attribute' ], # for demonstration's sake
+ traits => [ 'TestRole' ],
+ isa => 'Int',
+ does => 'Bar',
+ handles => { },
+ reader => 'foo',
+ builder => '_build_foo',
+ default => undef,
+ init_arg => 'foo',
+ lazy => 1,
+ );
Not yet documented or tested exhaustively; please see t/validate_attribute.t
-for usage details until released in a non TRIAL form.
+for details at the moment. This test routine is likely to change in
+implementation and scope, with every effort to maintain backwards
+compatibility.
=head2 attribute_options_ok
-Validates that an attribute is set up as expected.
+Validates that an attribute is set up as expected; like validate_attribute(),
+but only concerns itself with attribute options.
Not yet documented or tested exhaustively; please see t/validate_attribute.t
-for usage details until released in a non TRIAL form.
+for details at the moment. This test routine is likely to change in
+implementation and scope, with every effort to maintain backwards
+compatibility.
=head1 SEE ALSO

0 comments on commit 8c8bdcd

Please sign in to comment.