Example #1
0
 public function testRemoveComponentsData()
 {
     $configuration = ['key' => 'value'];
     $name = 'myName';
     $parentName = 'thisParentName';
     $configurationModel = new Configuration($name, $parentName, $configuration);
     $this->componentStorage = [$configurationModel->getName() => $configurationModel];
     $this->configurationStorage->addComponentsData($configurationModel);
     $this->assertEquals($configurationModel, $this->configurationStorage->getComponentsData($name));
     $this->configurationStorage->removeComponentsData($configurationModel);
     $this->assertEquals(null, $this->configurationStorage->getComponentsData($name));
 }
 public function testGetParentName()
 {
     $this->assertEquals($this->parentName, $this->configurationModel->getParentName());
 }