Example #1
0
 public function testEntityIsAttachedToSessionAfterInserting()
 {
     $bug = new Bug('name', 1);
     $this->assertFalse($this->session->isAttached($bug));
     $this->session->save($bug);
     // HACK:
     $this->assertNotNull($this->session->getIdentityMap()->get('Bug', 1));
 }
Example #2
0
 public function __construct(OutletSession $session)
 {
     $this->session = $session;
     $this->config = $session->getConfig();
     $this->repository = $session->getRepository();
     $this->identityMap = $session->getIdentityMap();
 }