Merge pull request #1174 from ClaraLeigh/feat/presets

feature(presets): Add security preset
This commit is contained in:
Nuno Maduro
2024-06-10 11:13:50 +01:00
committed by GitHub
3 changed files with 40 additions and 0 deletions

View File

@ -0,0 +1,29 @@
<?php
declare(strict_types=1);
namespace Pest\ArchPresets;
/**
* @internal
*/
final class Security extends AbstractPreset
{
/**
* Executes the arch preset.
*/
public function execute(): void
{
$this->expectations[] = expect([
'md5',
'sha1',
'uniqid',
'rand',
'mt_rand',
'tempnam',
'str_shuffle',
'shuffle',
'array_rand'
])->not->toBeUsed();
}
}