Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
Use triggering file to determine weak vendors if when the test is run in a separate process#25685
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
nicolas-grekas commentedJan 4, 2018
can you rebase on 3.4 please ? |
… in a separate process
4f05ef4 to14925cbComparealexpott commentedJan 4, 2018
Rebased on 3.4. I can't work out how to write a test for this because atm all the weak vendor stuff is tested via phpt tests and a fake vendor. |
| $msg =$parsedMsg['deprecation']; | ||
| $class =$parsedMsg['class']; | ||
| $method =$parsedMsg['method']; | ||
| $isWeak = DeprecationErrorHandler::MODE_WEAK ===$mode || (DeprecationErrorHandler::MODE_WEAK_VENDORS ===$mode &&$isVendor =$inVendors($parsedMsg['triggering_file'])); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
shouldn't $isVendor be initialized to false before this line?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
then L124:$isWeak = $isWeak || ...?
nicolas-grekasJan 4, 2018 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
self answering :)
shouldn't $isVendor be initialized to false before this line?
not needed as logically this wouldn't make a difference, but might still help the reader
then L124: $isWeak = $isWeak || ...?
really not sure about that (might instead break the fix, you'll tell :) )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Yeah that'd break the fix. The point is $isWeak is wrong at this point. Can always add a comment.
nicolas-grekas commentedJan 4, 2018
Thank you@alexpott. |
greg0ire commentedJan 5, 2018
Oh wow you fixed it, thanks! Could have pinged me though :P |
| // then we need to use the serialized information to | ||
| // determine if the error has been triggered from vendor | ||
| // code. | ||
| $isWeak = DeprecationErrorHandler::MODE_WEAK ===$mode || (DeprecationErrorHandler::MODE_WEAK_VENDORS ===$mode &&$isVendor =$inVendors($parsedMsg['triggering_file'])); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Very elegant solution 👍
Uh oh!
There was an error while loading.Please reload this page.