Followup for #20202, needed by #16546.
Allow the functional test suite to skip tests that require BDB, as well as introduce specific logic to handle whether BDB support is enabled or not. It follows the same pattern as skip_if_no_sqlite
and is_sqlite_compiled
.