MockSmsHandlerProvider   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Test Coverage

Coverage 100%
Metric Value
wmc 2
lcom 0
cbo 2
dl 0
loc 14
ccs 6
cts 6
cp 1
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A register() 0 6 1
A boot() 0 4 1
1
<?php
2
/**
3
 * This file is part of the Apiary SMS Login Provider package.
4
 *
5
 * (c) Darren Mothersele <[email protected]>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
11
namespace Apiary\SmsLoginProvider\SmsHandler;
12
13
use Silex\Application;
14
use Silex\ServiceProviderInterface;
15
16
class MockSmsHandlerProvider implements ServiceProviderInterface
17
{
18
    public function register(Application $app)
19
    {
20 9
        $app['sms.handler'] = $app->share(function () use ($app) {
21 6
            return new MockSmsHandler($app);
22 9
        });
23 9
    }
24
25 9
    public function boot(Application $app)
26
    {
27
        // Do nothing
28 9
    }
29
}
30