Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure that endChangeset() returns the real outcome
I was debugging a complex sniff that implies multiple potential modifications to the same token (that is, right now, not possible - we could discuss about that another day), when have detected that the Fixer::endChangeset() method is returning always true, no matter the changes have been not accepted. So this just ensures that the method returns the real outcome. I've been looking to current tests to try to add something to have it covered, but it seems that the Fixer is one of those areas needing some coverage, haven't found any test explicitly covering it. Also, I've searched at github, to see if anybody may be using expressions like: $outcome = $phpcsFile->fixer->endChangeset()... if ($phpcsFile->fixer->endChangeset()... And have found zero lines of code using the return value of the method. Hence, I think it's a safe change to apply.
- Loading branch information