Conditions | 3 |
Paths | 4 |
Total Lines | 12 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
18 | public function test_service_factory() |
||
19 | { |
||
20 | $client = new Client('mock', 'mock'); |
||
21 | |||
22 | foreach (ClassMap::SERVICES as $service => $class) { |
||
23 | $this->assertInstanceOf($class, $client->$service); |
||
24 | } |
||
25 | |||
26 | try { |
||
27 | $client->not_existant; |
||
|
|||
28 | $this->fail('Connector::__get should have thrown an error for a service that does not exist'); |
||
29 | } catch (BadMethodException $e) { |
||
30 | // Error should be thrown |
||
50 |