lincolnloop / django-alive

Healthchecks for Django
Other
37 stars 2 forks source link

allow to execute one test multiple times with different parameters #12

Closed PetrDlouhy closed 2 months ago

PetrDlouhy commented 1 year ago

I wanted to perform the check_cache test on all of my caches so I modified the code to allow set/array in ALIVE_CHECKS settings.

PetrDlouhy commented 8 months ago

@ipmb Could you please check this PR?

ipmb commented 8 months ago

I think the list of tuples format should be the default. We can keep dict support as a legacy/deprecated option.

PetrDlouhy commented 6 months ago

@ipmb Thanks for the comment. I have transformed the code, so that list of tuples is default. Dict now throws deprecated warning.

I have also added test for the old behavior. I had to move ALIVE_CHECKS variable to the function, otherwise the override_settings would not work.

All tests should pass when you pull #14

PetrDlouhy commented 2 months ago

@dchukhin Would you please look at this and #13 too?

PetrDlouhy commented 2 months ago

@ipmb Is everything OK with this PR or should I make some more effort?

ipmb commented 2 months ago

It's all good. I hope we can merge it soon... just doing some housekeeping to make this easier in the future.