Open nicolashohm opened 7 years ago
Sorry I didn't read the disclaimer in the README that only predis is supported. But anyway, please see this as a feature request 😉
Proper reflection signatures were added to phpredis in https://github.com/phpredis/phpredis/issues/1055
https://github.com/TysonAndre/RedisMock/commit/a98c233df3f1b38b6b3caabf95897944077eef5b seems to be working with 3.1.2 (I haven't checked if errors were suppressed)
NOTE: I haven't gotten around to running the test suites yet, I expect there to be failures to fix
We discovered an issue with phpredis.
We wan't to create a Redis mock to inject them into another class that expects an instance of
Redis
. Our solution now is to not use the factory but creatingRedisMock
directly, remove the typehint in our sut and inject the RedisMock directly.System Informations
OS: Linux PHP:
PHP 7.1.10-1+0~20170929170631.9+jessie~1.gbp501135 (cli)
phpredis: 3.1.2Reproduce
Error
More informations
we debugged a bit and found out that the reflection of
Redis
give no details about the parameters for most of the methods.