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

Fix PhpArrayDumper notice and PHP 5.3 compatibility #61

Merged
merged 8 commits into from
Jun 18, 2015
Merged

Fix PhpArrayDumper notice and PHP 5.3 compatibility #61

merged 8 commits into from
Jun 18, 2015

Conversation

drupol
Copy link
Collaborator

@drupol drupol commented Jun 16, 2015

No description provided.

@drupol drupol self-assigned this Jun 17, 2015
@LionsAd
Copy link
Owner

LionsAd commented Jun 17, 2015

Oh wow, when would that not be an object?

@LionsAd
Copy link
Owner

LionsAd commented Jun 17, 2015

It should be possible to unit test this?

Could we setup a scenario for that?

@drupol
Copy link
Collaborator Author

drupol commented Jun 17, 2015

Actually, there's nothing to test because:

$this->getServiceAliasDefinition($id);

Always returns an array, see: https://github.com/LionsAd/service_container/blob/7.x-1.x/lib/Drupal/Core/DependencyInjection/Dumper/PhpArrayDumper.php#L234

@drupol drupol changed the title Fix PhpArrayDumper notice when flushing caches. Fix PhpArrayDumper notice and PHP 5.3 compatibility Jun 18, 2015
$dump = unserialize($this->dumper->dump());

$this->assertTrue(is_array($dump));
$this->assertEquals($dump['services']['bar'], 'foo');
Copy link
Owner

Choose a reason for hiding this comment

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

Hm, but that should not be true.

It should actually be an array with [ 'alias': 'foo' ] set ...

Why do we need to change that?

@LionsAd LionsAd added RTBM and removed Needs review labels Jun 18, 2015
drupol added a commit that referenced this pull request Jun 18, 2015
Fix PhpArrayDumper notice and PHP 5.3 compatibility
@drupol drupol merged commit eb78cb1 into LionsAd:7.x-1.x Jun 18, 2015
@drupol drupol deleted the Fix-PhpArrayDumper-notice branch June 25, 2015 07:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants