Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[DX] Added line feed to container alias description (text descriptor) #11305

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

Merged
merged 1 commit into from
Jul 25, 2014

Conversation

zefrog
Copy link

@zefrog zefrog commented Jul 5, 2014

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets -
License MIT
Doc PR N/A

This PR just adds a line feed at the end of the alias service description delivered by the ContainerDebugCommand. Tests are passing because expected outputs are trimmed before comparison (which IMO is not a really good thing, but hey...)

@@ -273,7 +273,7 @@ protected function describeContainerDefinition(Definition $definition, array $op
*/
protected function describeContainerAlias(Alias $alias, array $options = array())
{
$this->writeText(sprintf('This service is an alias for the service <info>%s</info>', (string) $alias), $options);
$this->writeText(sprintf("This service is an alias for the service <info>%s</info>\n", (string) $alias), $options);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't it be better to use the system independent PHP_EOL constant instead of \n?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The whole file is using \n, see lines 60, 94, 110, 128...

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's only one use of PHP_EOL that's not testing related in the whole symfony/symfony repo. I don't remember why but I think that was a choice made by the the core at some point.

@zefrog
Copy link
Author

zefrog commented Jul 5, 2014

I think Travis failure is not related to my PR... Tests are passing :)

@fabpot
Copy link
Member

fabpot commented Jul 25, 2014

Thank you @zefrog.

@fabpot fabpot merged commit 13c011c into symfony:master Jul 25, 2014
fabpot added a commit that referenced this pull request Jul 25, 2014
…t descriptor) (Maxime Douailin)

This PR was merged into the 2.6-dev branch.

Discussion
----------

[DX] Added line feed to container alias description (text descriptor)

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | N/A

This PR just adds a line feed at the end of the alias service description delivered by the ContainerDebugCommand. Tests are passing because expected outputs are trimmed before comparison (which IMO is not a really good thing, but hey...)

Commits
-------

13c011c Added line feed to container alias description (text descriptor)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DX DX = Developer eXperience (anything that improves the experience of using Symfony)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants