All unit tests passing with refactored stuff, documentation updated significantly.
[gitmo/MooseX-AttributeHelpers.git] / t / 006_basic_bag.t
index a90bbc9..69fcbe8 100644 (file)
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use Test::More tests => 18;
+use Test::More tests => 19;
 use Test::Exception;
 
 BEGIN {
@@ -19,11 +19,12 @@ BEGIN {
         metaclass => 'Collection::Bag',
         is        => 'ro',
         provides  => {
-            'add'    => 'add_word',
-            'get'    => 'get_count_for',            
-            'empty'  => 'has_any_words',
-            'count'  => 'num_words',
-            'delete' => 'delete_word',
+            'add'       => 'add_word',
+            'get'       => 'get_count_for',            
+            'has_items' => 'has_any_words',
+            'is_empty'  => 'has_no_words',
+            'count'     => 'num_words',
+            'delete'    => 'delete_word',
         }
     );
 }
@@ -35,11 +36,12 @@ can_ok($stuff, $_) for qw[
     add_word
     get_count_for
     has_any_words
+    has_no_words
     num_words
     delete_word
 ];
 
-ok(!$stuff->has_any_words, '... we have no words');
+ok($stuff->has_no_words, '... we have no words');
 is($stuff->num_words, 0, '... we have no words');
 
 lives_ok {