ddev / ddev-addon-template

Template for DDEV add-ons.
Apache License 2.0
17 stars 17 forks source link

Move health checks to a separate function in bats test file #24

Closed MurzNN closed 1 year ago

MurzNN commented 1 year ago

Now, regarding to the template file, we have to write checks twice:

Will be good to move that to a separate function, to not have two places to manage them.

So, I've created a function health_checks() that contains only a single instance of checks.

And have moved it to the top, because it will be edited more frequiently, than test functions.

MurzNN commented 1 year ago

Seems bats doesn't support functions with all commented lines, so I've just added one real line there and it starts working: image