Skip to content

[Config] Extra tests for Config component #19399

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

Closed
wants to merge 4 commits into from
Closed

[Config] Extra tests for Config component #19399

wants to merge 4 commits into from

Conversation

zomberg
Copy link
Contributor

@zomberg zomberg commented Jul 21, 2016

Q A
Branch? 2.7
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets ~
License MIT
Doc PR ~

@zomberg zomberg changed the title [Config] Added extra tests for ArrayNodeDefinition class [Config] Extra tests for Config component Jul 22, 2016
{
$builder = $this->getTestBuilder();

$reflection = new \ReflectionProperty($builder, 'ifPart');
Copy link
Contributor

Choose a reason for hiding this comment

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

Why do you need reflection here?

Copy link
Contributor Author

@zomberg zomberg Jul 22, 2016

Choose a reason for hiding this comment

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

Thanks. You are right. I didn't notice that this is public property. I fixed it.

@javiereguiluz
Copy link
Member

👍

Status: reviewed

@zomberg thanks for adding these missing tests!

$this->assertEquals(array('enabled' => false), $this->getField($node, 'falseEquivalent'));
$this->assertEquals(array('enabled' => true), $this->getField($node, 'trueEquivalent'));
$this->assertEquals(array('enabled' => true), $this->getField($node, 'nullEquivalent'));
$this->assertEquals(array('enabled' => true), $this->getField($node, 'nullEquivalent'));
Copy link
Member

Choose a reason for hiding this comment

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

duplicated line?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@nicolas-grekas
Copy link
Member

👍 with minor comment

@nicolas-grekas
Copy link
Member

Thank you @zomberg.

nicolas-grekas added a commit that referenced this pull request Jul 26, 2016
This PR was squashed before being merged into the 2.7 branch (closes #19399).

Discussion
----------

[Config] Extra tests for Config component

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

Commits
-------

d0f4434 [Config] Extra tests for Config component
@zomberg zomberg deleted the config_component_tests branch July 26, 2016 12:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants