-
Notifications
You must be signed in to change notification settings - Fork 72
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
#354 Make sure language types are always in the symbol whitelist #355
#354 Make sure language types are always in the symbol whitelist #355
Conversation
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.
LGTM 👍
Some CS changes needed |
Yes, I will take care of it. |
Should we also remove the whitelist part on the default config json to prevent confusion on this topic? |
Can certainly be done 👍 |
…nguage types are always included
@DanielBadura @Ocramius Please let me know if this is satisfactory or feel free to merge. |
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.
There is one mutant to be fixed, indicating a missing test:
2) /home/runner/work/ComposerRequireChecker/ComposerRequireChecker/src/ComposerRequireChecker/Cli/Options.php:108 [M] UnwrapArrayUnique
--- Original
+++ New
@@ @@
* Make sure the language types (e.g. 'true', 'false', 'object', 'mixed') are always included in the symbol
* whitelist. If these are omitted the results can be pretty unexpected.
*/
- $this->symbolWhitelist = array_unique(array_merge(self::PHP_LANGUAGE_TYPES, $symbolWhitelist));
+ $this->symbolWhitelist = array_merge(self::PHP_LANGUAGE_TYPES, $symbolWhitelist);
}
/**
* @param array<string> $phpCoreExtensions
Cheers, I added an assertion that should fix it |
Thanks @willemstuursma! |
The language types should always be in the whitelist. Else, ComposerRequireChecker will give errors like: