open-orchestra/open-orchestra-cms-bundle

View on GitHub
WorkflowAdminBundle/DataFixtures/MongoDB/LoadWorkflowProfileDataFunctional.php

Summary

Maintainability
A
0 mins
Test Coverage

Class extends undeclared class \Doctrine\Common\DataFixtures\AbstractFixture
Open

class LoadWorkflowProfileDataFunctional extends AbstractFixture implements OrderedFixtureInterface,OrchestraFunctionalFixturesInterface

Class implements undeclared interface \Doctrine\Common\DataFixtures\OrderedFixtureInterface
Open

class LoadWorkflowProfileDataFunctional extends AbstractFixture implements OrderedFixtureInterface,OrchestraFunctionalFixturesInterface

Call to undeclared method \OpenOrchestra\WorkflowAdminBundle\DataFixtures\MongoDB\LoadWorkflowProfileDataFunctional::getReference
Open

        $transition->setStatusTo($this->getReference($statusToReference));

Call to undeclared method \OpenOrchestra\WorkflowAdminBundle\DataFixtures\MongoDB\LoadWorkflowProfileDataFunctional::addReference
Open

        $this->addReference('profile-' . $referenceName, $profile);

Parameter $manager has undeclared type \Doctrine\Common\Persistence\ObjectManager
Open

    public function load(ObjectManager $manager)

Call to method persist from undeclared class \Doctrine\Common\Persistence\ObjectManager
Open

        $manager->persist($profileContributor);

Call to method setStatusTo from undeclared class \OpenOrchestra\ModelBundle\Document\WorkflowTransition
Open

        $transition->setStatusTo($this->getReference($statusToReference));

Call to undeclared method \OpenOrchestra\WorkflowAdminBundle\DataFixtures\MongoDB\LoadWorkflowProfileDataFunctional::getReference
Open

        $transition->setStatusFrom($this->getReference($statusFromReference));

Call to method __construct from undeclared class \OpenOrchestra\ModelBundle\Document\WorkflowProfile
Open

        $profile = new WorkflowProfile();

Call to method setLabels from undeclared class \OpenOrchestra\ModelBundle\Document\WorkflowProfile
Open

        $profile->setLabels($labels);

Call to method setStatusFrom from undeclared class \OpenOrchestra\ModelBundle\Document\WorkflowTransition
Open

        $transition->setStatusFrom($this->getReference($statusFromReference));

Return type of createProfile() is undeclared type \OpenOrchestra\ModelBundle\Document\WorkflowProfile
Open

    protected function createProfile(array $labels, array $descriptions, array $transitions, $referenceName)

Call to method addTransition from undeclared class \OpenOrchestra\ModelBundle\Document\WorkflowProfile
Open

            $profile->addTransition($transition);

Parameter $transitions has undeclared type \OpenOrchestra\ModelBundle\Document\WorkflowTransition[]
Open

    protected function createProfile(array $labels, array $descriptions, array $transitions, $referenceName)

Call to method flush from undeclared class \Doctrine\Common\Persistence\ObjectManager
Open

        $manager->flush();

Call to method __construct from undeclared class \OpenOrchestra\ModelBundle\Document\WorkflowTransition
Open

        $transition = new WorkflowTransition();

Return type of createTransition() is undeclared type \OpenOrchestra\ModelBundle\Document\WorkflowTransition
Open

    protected function createTransition($statusFromReference, $statusToReference)

Call to method setDescriptions from undeclared class \OpenOrchestra\ModelBundle\Document\WorkflowProfile
Open

        $profile->setDescriptions($descriptions);

Class implements undeclared interface \OpenOrchestra\ModelInterface\DataFixtures\OrchestraFunctionalFixturesInterface
Open

class LoadWorkflowProfileDataFunctional extends AbstractFixture implements OrderedFixtureInterface,OrchestraFunctionalFixturesInterface

Call to method persist from undeclared class \Doctrine\Common\Persistence\ObjectManager
Open

        $manager->persist($profileValidator);

Avoid excessively long variable names like $transitionDraftToPending. Keep variable name length under 20.
Open

        $transitionDraftToPending = $this->createTransition('status-draft', 'status-pending');

LongVariable

Since: 0.2

Detects when a field, formal or local variable is declared with a long name.

Example

class Something {
    protected $reallyLongIntName = -3; // VIOLATION - Field
    public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
        $otherReallyLongName = -5; // VIOLATION - Local
        for ($interestingIntIndex = 0; // VIOLATION - For
             $interestingIntIndex < 10;
             $interestingIntIndex++ ) {
        }
    }
}

Source https://phpmd.org/rules/naming.html#longvariable

Avoid excessively long variable names like $transitionDraftToPublished. Keep variable name length under 20.
Open

        $transitionDraftToPublished = $this->createTransition('status-draft', 'status-published');

LongVariable

Since: 0.2

Detects when a field, formal or local variable is declared with a long name.

Example

class Something {
    protected $reallyLongIntName = -3; // VIOLATION - Field
    public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
        $otherReallyLongName = -5; // VIOLATION - Local
        for ($interestingIntIndex = 0; // VIOLATION - For
             $interestingIntIndex < 10;
             $interestingIntIndex++ ) {
        }
    }
}

Source https://phpmd.org/rules/naming.html#longvariable

Avoid excessively long variable names like $transitionPendingToPublished. Keep variable name length under 20.
Open

        $transitionPendingToPublished = $this->createTransition('status-pending', 'status-published');

LongVariable

Since: 0.2

Detects when a field, formal or local variable is declared with a long name.

Example

class Something {
    protected $reallyLongIntName = -3; // VIOLATION - Field
    public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
        $otherReallyLongName = -5; // VIOLATION - Local
        for ($interestingIntIndex = 0; // VIOLATION - For
             $interestingIntIndex < 10;
             $interestingIntIndex++ ) {
        }
    }
}

Source https://phpmd.org/rules/naming.html#longvariable

Avoid excessively long variable names like $transitionToTranslateToPending. Keep variable name length under 20.
Open

        $transitionToTranslateToPending = $this->createTransition('status-toTranslate', 'status-pending');

LongVariable

Since: 0.2

Detects when a field, formal or local variable is declared with a long name.

Example

class Something {
    protected $reallyLongIntName = -3; // VIOLATION - Field
    public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
        $otherReallyLongName = -5; // VIOLATION - Local
        for ($interestingIntIndex = 0; // VIOLATION - For
             $interestingIntIndex < 10;
             $interestingIntIndex++ ) {
        }
    }
}

Source https://phpmd.org/rules/naming.html#longvariable

Avoid excessively long variable names like $transitionPublishedToDraft. Keep variable name length under 20.
Open

        $transitionPublishedToDraft = $this->createTransition('status-published', 'status-draft');

LongVariable

Since: 0.2

Detects when a field, formal or local variable is declared with a long name.

Example

class Something {
    protected $reallyLongIntName = -3; // VIOLATION - Field
    public static function main( array $interestingArgumentsList[] ) { // VIOLATION - Formal
        $otherReallyLongName = -5; // VIOLATION - Local
        for ($interestingIntIndex = 0; // VIOLATION - For
             $interestingIntIndex < 10;
             $interestingIntIndex++ ) {
        }
    }
}

Source https://phpmd.org/rules/naming.html#longvariable

Expected 1 space before "OrchestraFunctionalFixturesInterface"; 0 found
Open

class LoadWorkflowProfileDataFunctional extends AbstractFixture implements OrderedFixtureInterface,OrchestraFunctionalFixturesInterface

Line exceeds 120 characters; contains 176 characters
Open

            array('en' => 'Member which must submit his content to validation for publication', 'fr' => 'Membre qui doit soumettre son contenu à validation pour publication'),

Line exceeds 120 characters; contains 135 characters
Open

class LoadWorkflowProfileDataFunctional extends AbstractFixture implements OrderedFixtureInterface,OrchestraFunctionalFixturesInterface

There are no issues that match your filters.

Category
Status