Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed coding standard violations in the Framework\ObjectManager namespace #9362

Merged
merged 1 commit into from
Jun 23, 2017
Merged

Fixed coding standard violations in the Framework\ObjectManager namespace #9362

merged 1 commit into from
Jun 23, 2017

Conversation

dverkade
Copy link
Member

@dverkade dverkade commented Apr 22, 2017

Fixed coding standard violations in the Framework\ObjectManager namespace, so that it will be checked bij PHP CS and no longer be ignored while doing CI checks. Made the following changes:

  • Removed @codingStandardsIgnoreFile from the head of the file.

@orlangur
Copy link
Contributor

This PR can be closed as I've done such changes automatically.

@dverkade
Copy link
Member Author

@orlangur This changes are still in the develop branch. I cann't see any open pull requests for these files. So this can be merged. If you are finished with your work you can reference a pull request in this commit and it's up to @magento-team which PR they are accepting.

@dverkade
Copy link
Member Author

@magento-team I still have the ConfigDomMock class which has the @codingStandardsIgnoreFile in the head of the file. I was not able to remove this one, because it throws an error because the class is in the root namespace and does not contain a vendor name. What is the technical vision of Magento for these type of classes?

I'm suggesting the following solution: Put this file in the "Magento\Framework\ObjectManager\Test\Unit\Config\Reader" namespace and update the test including/referincing this file to the correct new class name.

@orlangur
Copy link
Contributor

@dverkade,

I cann't see any open pull requests for these files

I do not post unprepared pull requests ;) Just trying to minimize conflicts with useless manual changes. Thanks for your other today PRs as they really cover what I postponed for now 👍 I've already finished stabilization of draft branch, creating clean branch out of develop is a matter of hours (would be some 30 minutes with SSD env 😄 ).

What is the technical vision of Magento for these type of classes?

class ConfigDomMock extends \PHPUnit_Framework_TestCase this is some evil mix of stub and test case. Technically you can put it somewhere near \Magento\Framework\ObjectManager\Test\Unit\Config\Reader\DomTest but the better way would be to refactor a unit test in such a way that you test code behavior and not flow. We shall just test output of $this->model->read(); call.

@maghamed maghamed self-requested a review April 24, 2017 10:53
@maghamed maghamed self-assigned this Apr 24, 2017
@orlangur
Copy link
Contributor

orlangur commented May 3, 2017

This change is covered by #9367 by the way.

@ishakhsuvarov ishakhsuvarov self-assigned this Jun 23, 2017
@ishakhsuvarov ishakhsuvarov added this to the June 2017 milestone Jun 23, 2017
@magento-team magento-team merged commit 0b2cc10 into magento:develop Jun 23, 2017
magento-team pushed a commit that referenced this pull request Jun 23, 2017
@dverkade dverkade deleted the Fix_coding_standard_in_Framework-ObjectManager branch June 22, 2018 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants