Example #1
0
 public function testSetStore()
 {
     $adapter = new Erfurt_Store_Adapter_Test();
     $store = new Erfurt_Store(array('adapterInstance' => $adapter), 'Test');
     $this->assertNotSame($this->_instances->getStore(), $store);
     $this->_instances->setStore($store);
     $this->assertSame($this->_instances->getStore(), $store);
     try {
         $this->_instances->setStore(null);
         $this->fail("No Exception was thrown in setStore(null)");
     } catch (Exception $e) {
         $this->assertTrue(true);
         //increase assertion count :)
     }
 }