GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

ConvertTest::provideObjectsAndArrays()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 14
Code Lines 10

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 14
rs 9.4285
cc 1
eloc 10
nc 1
nop 0
1
<?php
2
3
namespace prgTW\BaseCRM\Tests\Utils;
4
5
use prgTW\BaseCRM\Utils\Convert;
6
7
class ConvertTest extends \PHPUnit_Framework_TestCase
8
{
9
	/**
10
	 * @dataProvider provideObjectsAndArrays
11
	 *
12
	 * @param object $object
13
	 * @param array  $array
14
	 */
15
	public function testObjectToArray($object, array $array)
16
	{
17
		$converted = Convert::objectToArray($object);
18
		$this->assertEquals($array, $converted);
19
	}
20
21
	public function provideObjectsAndArrays()
22
	{
23
		$obj1          = new \stdClass();
24
		$obj1->a       = 1;
25
		$obj1->b       = new \stdClass();
26
		$obj1->b->c    = 2;
27
		$obj1->b->d    = new \stdClass();
28
		$obj1->b->d->e = 3;
29
30
		return [
31
			[new \stdClass(), []],
32
			[$obj1, ['a' => 1, 'b' => ['c' => 2, 'd' => ['e' => 3]]]],
33
		];
34
	}
35
36
}
37