Conditions | 1 |
Paths | 1 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
9 | public function testGetKey() |
||
10 | { |
||
11 | $this->mockHttpSession($this->body_keys); |
||
|
|||
12 | |||
13 | $keys = $this->moip->keys()->get(); |
||
14 | |||
15 | $this->assertNotNull($keys->getBasicAuth()->token); |
||
16 | $this->assertNotNull($keys->getBasicAuth()->secret); |
||
17 | $this->assertNotNull($keys->getEncryption()); |
||
18 | } |
||
19 | } |
||
20 |
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: