/**
  * @test
  */
 public function shouldReturnAccountWithBugs()
 {
     //when
     $account = Account::where(array('name' => "LIKE 'Air Sa%'"))->fetch();
     //then
     Assert::thatArray($account->bugs)->hasSize(2)->onProperty('name')->containsOnly("Syntax error appears when running old reports", "Broken image appears in home page");
 }
 /**
  * @test
  */
 public function shouldSetRelationship()
 {
     //given
     $account = new Account();
     $account->name = 'New Company';
     $account->insert();
     $contact = new Contact();
     $contact->first_name = 'John';
     $contact->last_name = 'Doe';
     $contact->insert();
     //when
     $account->relatedWith($contact);
     //then
     $search = Account::findById($account->id);
     Assert::thatArray($search->contacts)->hasSize(1);
 }
 protected function setUp()
 {
     parent::setUp();
     $account = new Account();
     $this->moduleDbName = $account->getModuleDbName();
 }