| Conditions | 2 |
| Paths | 2 |
| Total Lines | 16 |
| Code Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 24 | public static function getSample() |
||
| 25 | { |
||
| 26 | $file_name = self::newTempFile(); |
||
| 27 | $resource = fopen($file_name, 'rb'); |
||
| 28 | fclose($resource); |
||
|
|
|||
| 29 | $unknown = $resource; |
||
| 30 | yield [$unknown]; |
||
| 31 | |||
| 32 | /** @noinspection PhpUsageOfSilenceOperatorInspection */ |
||
| 33 | @unlink($file_name); |
||
| 34 | |||
| 35 | if (function_exists('imagecreate')) { |
||
| 36 | $resource = \imagecreate(1, 1); |
||
| 37 | \imagedestroy($resource); |
||
| 38 | $unknown = $resource; |
||
| 39 | yield [$unknown]; |
||
| 40 | } |
||
| 50 | } |