Completed
Push — master ( a682ba...4851b3 )
by Paweł
40:50
created

LoadTenantsData   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 26
ccs 8
cts 8
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A load() 0 12 1
A getOrder() 0 4 1
1
<?php
2
/*
3
 * This file is part of the Superdesk Web Publisher Fixtures Bundle.
4
 *
5
 * Copyright 2015 Sourcefabric z.u. and contributors.
6
 *
7
 * For the full copyright and license information, please see the
8
 * AUTHORS and LICENSE files distributed with this source code.
9
 *
10
 * @copyright 2015 Sourcefabric z.ú
11
 * @license http://www.superdesk.org/license
12
 */
13
14
namespace SWP\Bundle\FixturesBundle\DataFixtures\ORM;
15
16
use Doctrine\Common\DataFixtures\FixtureInterface;
17
use Doctrine\Common\DataFixtures\OrderedFixtureInterface;
18
use Doctrine\Common\Persistence\ObjectManager;
19
use SWP\Bundle\FixturesBundle\AbstractFixture;
20
21
class LoadTenantsData extends AbstractFixture implements FixtureInterface, OrderedFixtureInterface
22
{
23
    /**
24
     * {@inheritdoc}
25
     */
26 103
    public function load(ObjectManager $manager)
27
    {
28 103
        $env = $this->getEnvironment();
29
30 103
        $this->loadFixtures(
31
            [
32 103
                '@SWPFixturesBundle/Resources/fixtures/ORM/'.$env.'/organization.yml',
33 103
                '@SWPFixturesBundle/Resources/fixtures/ORM/'.$env.'/tenant.yml',
34
            ],
35
            $manager
36
        );
37 103
    }
38
39
    /**
40
     * {@inheritdoc}
41
     */
42 50
    public function getOrder()
43
    {
44 50
        return 0;
45
    }
46
}
47