pytest-redis icon indicating copy to clipboard operation
pytest-redis copied to clipboard

fix issue #656: add 'modules' keyword arg to load Redis extension modules

Open mguijarr opened this issue 1 year ago • 6 comments

Here is a pull request to close #656 , taking into account comments in : https://github.com/ClearcodeHQ/pytest-redis/pull/657

(sorry had to create a new pull request... Not super at ease with github vs gitlab !)

mguijarr avatar May 10 '24 13:05 mguijarr

@mguijarr one last thing.... would you be able to add some tests as well?

fizyk avatar May 10 '24 13:05 fizyk

Oh, one last thing, please mention in the documentation that it will not work for noproc fixtures.

fizyk avatar May 10 '24 13:05 fizyk

@mguijarr one last thing.... would you be able to add some tests as well?

I added a test, just for modules keyword argument (didn't find the tests for pytest.ini and pytest command line args)

mguijarr avatar May 12 '24 09:05 mguijarr

Oh, one last thing, please mention in the documentation that it will not work for noproc fixtures.

I thought it was done already ? In the table, it has - for noproc-fixture column

mguijarr avatar May 12 '24 09:05 mguijarr

I thought it was done already ? In the table, it has - for noproc-fixture column

Yeah, the column lists configuration for the fixture if you'd want to use the fixture factory, and pass your own values there. There's nothing else stating that if you configure from command line or config file, it will not affect the redis connected to through noproc fixture.

fizyk avatar May 13 '24 10:05 fizyk

I thought it was done already ? In the table, it has - for noproc-fixture column

Yeah, the column lists configuration for the fixture if you'd want to use the fixture factory, and pass your own values there. There's nothing else stating that if you configure from command line or config file, it will not affect the redis connected to through noproc fixture.

I just added more descriptive documentation

mguijarr avatar May 14 '24 12:05 mguijarr

@mguijarr now, there are some issues with mypy now and the ruff linter left :)

fizyk avatar May 17 '24 09:05 fizyk

Sorry for the long delay, have been busy - ok I tried to make mypy happy and I applied ruff

mguijarr avatar May 26 '24 21:05 mguijarr

Ok thanks for approval to let tests pass.. Again it fails with mypy 😭

No idea what is wrong

mguijarr avatar May 29 '24 09:05 mguijarr

I don't use mypy maybe you can make the fix yourself ? If you don't mind

mguijarr avatar May 29 '24 09:05 mguijarr

I'll try to take a look sometimes next week :)

fizyk avatar May 29 '24 15:05 fizyk

Looks nice 🥳 Is it ready to merge soon?

mguijarr avatar Jun 04 '24 13:06 mguijarr

Thanks a lot! 👍🏻 And a great thank you for pytest-redis, very useful

mguijarr avatar Jun 05 '24 15:06 mguijarr

Thank you for your contribution :)

Wait a bit, till I add python 3.12 proper support, and redis 7.2 into tests and I'll be releasing new version :)

fizyk avatar Jun 05 '24 15:06 fizyk