GenOO

 view release on metacpan or  search on metacpan

cookbook/08-Test_Suite.md  view on Meta::CPAN

	my @test_objects;
	push @test_objects, Person::Employee->new(
		first_name => $person->first_name,
		salary     => '50000';
	)
	
	return \@test_objects;
}
```
Given the above test classes, when `Test::Person::Employee` is run it will successfully test for `fisrt_name` and `salary`.
See how `John` cascades throught the inheritance tree?


# Using Test::Class::Moose
As you may have noticed, the code in the previous example is a little bit scetchy. The reason is that the method `Test::Person::Employee::test_objects` uses the instantiated objects provided by `Test::Person::test_objects` to just access the data. It...
Using these two new methods and `Test::Class::Moose` the above code for `Person` becomes:

```perl
package Test::Person;

use Test::Class::Moose;



( run in 0.638 second using v1.01-cache-2.11-cpan-49f99fa48dc )