/** * @dataProvider dataProvider */ public function testGetLocationDetails($imsi, $data) { $sim = new SimModel(); $sim->setImsi($imsi); $this->simMapper->getLocationDetails($sim); $this->assertNotNull($sim->getLocationManual()); $this->checkModelAgainstStruct($sim->getLocationManual(), 'presence test', $data['location']['provisioned']); }
public function testGetKeepAliveHistory() { $sim = new \Application\Model\SimModel(); $sim->setImsi("214071000000002"); $from = '2008-11-15T21:07+0000'; $until = '2012-12-14T21:07+0000'; $data = $this->simMapper->getKeepAliveHistory($sim, $from, $until); // Structure $this->assertInternalType('array', $data); $this->assertNotEmpty($data); $this->assertArrayHasKey('timestamp', $data[0]); $this->assertArrayHasKey('status', $data[0]); // Count $this->assertEquals(2, count($data)); }