Exemplo n.º 1
0
 public function traits_are_mixins_that_can_be_shared()
 {
     // ActiveRecord is built with the programming by concerns model, which
     // uses multiple traits.
     // see: http://37signals.com/svn/posts/3372-put-chubby-models-on-a-diet-with-concerns
     $entreprenur = new Entrepreneur();
     $entreprenur->split_wealth(5000);
     $entreprenur->go_shopping();
     $entreprenur->go_shopping();
     assert_that($entreprenur->get_cash())->is_identical_to(__);
 }