« Introduction au test logiciel/Tests unitaires/PHPUnit » : différence entre les versions

Contenu supprimé Contenu ajouté
Ligne 158 :
 
==== willThrowException() ====
Pour qu'un mock lancesimule une erreur. Ex :
<source lang=php>
$monObjetTestémonMock->method('MaMéthode3')->willThrowException(new Exception());
</source>