The first fail logic seems scoped to a single test file.
Set the flag globally.
Since the tests run in a container, cleanup is automagic.
Various test tweaks to allow for skipping tests & null strings.
The test harness will suppress output unless an error occurs.
Upgrade testing was failing in forked repos CI because the
source repo was hard-coded. Use the CI environment to use
the fork's repo.
debug() does this, but the automated tests aren't run with -d.
This also ensures that there is a breadcrumb if error_exit is
called without a preceding debug().
It's really hard to follow the breadcrumbs for debug when there
aren't any.
--insecure is almost always a bad idea. In this case, it
is required for compatibility with Let's Encrypt.
Replace the less obvious '-k' with '--insecure' in the cURL
command, and document why it is used in the comments,
When a suffix is applied to a filename lacking an extension,
a '.' in the host name is treated as the extension, and
the extension is inserted there instead of being appended
to the filename.
Inspect the basename of the destination, and append only the
suffix if no extension is present.
Thus ssh:host.example.net:/etc/ssl/private/foo will now be
copied to host.example.net/etc/ssl/private/foo.suffix instead
of host.example.suffix.net/etc./ssl/private/foo (which usually would fail).
Note that a local file, such as /etc/ssl/private/foo will
be copied to /etc/ssl/private/foo.suffix. (Not
/etc/ssl/private/foo.suffix. as before, which was incorrect).
Use a regexp rather than a partial match to skip any DNS_CHECK_OPTIONS,
which in the current tests create whitespace, but could be anything.
Catch a missing inclusion of DNS_CHECK_OPTIONS for dig CNAME