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.

FirephpFactoryTest   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 4

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 4
dl 0
loc 18
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A setUp() 0 4 1
A testFirephpFactoryCanBeInitalized() 0 8 1
1
<?php
2
/*
3
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
4
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
5
 * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
6
 * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
7
 * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
8
 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
9
 */
10
11
namespace MpaFirephpWrapperTest\Service;
12
13
use MpaFirephpWrapper\Service\FirephpFactory;
14
use MpaFirephpWrapper\Service\FirephpWrapper;
15
use MpaFirephpWrapperTest\Util\ServiceManagerFactory;
16
use PHPUnit\Framework\TestCase;
17
18
class FirephpFactoryTest extends TestCase
19
{
20
    protected $serviceManager;
21
22
    protected function setUp()
23
    {
24
        $this->serviceManager = ServiceManagerFactory::getServiceManager();
25
    }
26
27
    public function testFirephpFactoryCanBeInitalized()
28
    {
29
        $this->serviceManager->setService('firephptest', $this->createMock(FirephpFactory::class));
30
31
        $factory = new FirephpFactory();
32
        $result = $factory->createService($this->serviceManager);
33
        $this->assertInstanceOf(FirephpWrapper::class, $result);
34
    }
35
}
36