generated from pestphp/pest-plugin-template
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This PR adds the ability to be able to specify a language. By default, the check will loop over any files with the `profanities` directory, but personally, I really only care about words in the en.php file. I've had a couple of instances where words within words are picked up within other language files. By specifying `en` as the language, I can be sure that my codebase is only getting scanned against the correct file. My use case is one of my applications references "Customer". The word "Customer" contains "Cu" which is listed as profane in the pt_BR.php file because in Portuguese, it means "ass".
- Loading branch information
Showing
5 changed files
with
51 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Tests\Fixtures; | ||
|
||
class HasDifferentLanguageProfanity | ||
{ | ||
/** | ||
* just a merda comment | ||
*/ | ||
public function __construct( | ||
// | ||
) {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters