Skip to content

Ensure that object class contains path from root namespace #117

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
Sep 21, 2022

Conversation

pionl
Copy link
Contributor

@pionl pionl commented Sep 21, 2022

  • bug fix
  • BC break? no

Hi,

at first thank you for the package.

I've found that created objects in default parameters in methods does not contain valid class path (it should be from a root, currently uses namespace of the file which is incorrect).

This PR ensures that the object class always uses root path namespace.

Here is current "broken" expectation in my test:

I'm using $assertMethod = (new Factory())->fromMethodReflection($method);

Also I've noticed a deprecated usage of (string) reflectionType (it is deprecated since 7.1). I've currently implemented possible alternative solution (should cover everything I've found):

If you are interested I can contribute it to the factory (so a I can later us it?).

Have a great day,

@dg
Copy link
Member

dg commented Sep 21, 2022

Thanks

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.

2 participants