/** * @group EricssonTariffPlanInt */ public function testTariffPlanServicesFindByCustomer() { if ($this->_user->getId()) { $this->_user->delete(); } $this->_user = $this->_createAuthUser(array('userName' => 'TariffPlanUserIntegrationTest1-' . microtime(true), 'organizationId' => 'customer-the_second_customer2222222222222')); $tariffplan = $this->TariffPlanServicesMapper->findOneById(1); unset($this->testData['name']); unset($this->testData['description']); unset($this->testData['currencyId']); $this->assertEquals($this->testArray, $tariffplan->getResponseData()); }
/** * @group EricssonLifeCycleInt */ public function testChangeState() { if ($this->_user->getId()) { $this->_user->delete(); } $this->_user = $this->_createAuthUser(array('userName' => 'LifeCycleUserIntegrationTest1-' . microtime(true), 'organizationId' => 'customer-the_second_customer2222222222222')); $data = array('subscription_id' => array('id' => '34609100100', 'id_type' => 'MSISDN'), 'old_state' => 'INACTIVE_NEW', 'new_state' => 'ACTIVE', 'cost' => 500); $result = $this->lifecycleMapper->modifyStatusEricsson($data, 'customer-the_second_customer2222222222222'); $this->assertEquals(true, $result); }
/** * @group EricssonRestrictionInt */ public function testFindAll2() { if ($this->_user->getId()) { $this->_user->delete(); } $this->_user = $this->_createAuthUser(array('userName' => 'RestrictionUserIntegrationTest2-' . microtime(true), 'organizationId' => 'provider-sp1 (commercial)1111111111111112')); $restrictions = $this->restictionMapper->findAll(); $this->assertNotNull($restrictions); $this->assertEquals(2, $restrictions->getCount()); $items = $restrictions->getItems(); $this->assertEquals(2, count($items)); $ericssonData = array(array('id' => '3', 'name' => 'ALL RESTRICTION COMM', 'description' => 'ALL RESTRICTION COMM', 'serviceProviderId' => 'provider-sp1 (commercial)1111111111111112', 'serviceProviderName' => 'sp2 (commercial)'), array('id' => '4', 'name' => 'DATA RESTRICTION COMM', 'description' => 'DATA RESTRICTION COMM', 'serviceProviderId' => 'provider-sp1 (commercial)1111111111111112', 'serviceProviderName' => 'sp2 (commercial)')); $i = 0; foreach ($items as $item) { $this->assertInstanceOf('\\Application\\Model\\RestrictionModel', $item); $this->assertEquals($ericssonData[$i]['id'], $item->getId()); $this->assertEquals($ericssonData[$i]['name'], $item->getName()); $this->assertEquals($ericssonData[$i]['description'], $item->getDescription()); $this->assertEquals($ericssonData[$i]['serviceProviderId'], $item->getServiceProviderId()); $this->assertEquals($ericssonData[$i]['serviceProviderName'], $item->getServiceProviderName()); $i++; } }
/** * @group EricssonTariffPlanLifeCycleInt */ public function testFindTariffPlanLifeCycle2() { if ($this->_user->getId()) { $this->_user->delete(); } $this->_user = $this->_createAuthUser(array('userName' => 'TariffPlanUserIntegrationTest1-' . microtime(true), 'organizationId' => 'customer-the_second_customer2222222222222')); $tariffplanLifecycle = $this->tariffplanLifecycleMapper->findOneById(1, 2); $this->assertEquals(1, $tariffplanLifecycle->getLifeCycleId()); $this->assertEquals('commercial', $tariffplanLifecycle->getLifeCycleName()); $this->assertEquals('LC2', $tariffplanLifecycle->getName()); $this->assertEquals('Description2', $tariffplanLifecycle->getDescription()); $this->assertEquals('978', $tariffplanLifecycle->getCurrencyId()); $this->assertEquals($this->testArray2, $tariffplanLifecycle->getData()); }
public function tearDown() { if ($this->_user->getId()) { $this->_user->delete(); } }