michaelpetri / phpunit-consecutive-arguments
Replacement for the removed InvocationMocker::withConsecutive method.
0.3.0
2024-05-06 05:58 UTC
Requires
- php: ~8.2.0 || ~8.3.0
- phpunit/phpunit: ^10.2 || ^11.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.15.1
- psalm/phar: ^5.24
- rector/rector: ^0.18.0
- roave/security-advisories: dev-latest
Conflicts
This package is auto-updated.
Last update: 2024-05-17 08:48:29 UTC
README
Replacement for the removed InvocationMocker::withConsecutive method.
Installation
composer require michaelpetri/phpunit-consecutive-arguments
Example
$mock ->expects(self::exactly(\count(2))) ->method('someMethod') ->with( ...ConsecutiveArguments::of( ['1.1', '1.2'], ['2.1', '2.2'], );
See Tests for more examples