During local LODE builds on macOS, the test framework sets UNO_PATH
to `instdir/program`. While this works for Linux and Windows, macOS
builds generate a native application bundle, placing the executable
at `instdir/LibreOfficeDev.app/Contents/MacOS/soffice`.
This caused `subprocess.Popen` to throw a `FileNotFoundError` during
execution of targets like `PythonTest_pyuno_pytests_testofficehelper`.
This patch intercepts the macOS path in `bootstrap()` and dynamically
routes it to the correct LibreOfficeDev App Bundle location if the
default Linux-style path does not exist.
Additionally, this adds a standard Python 3 shebang to the file and
fixes a missing newline at EOF.
Change-Id: Ie92415941c24e0777087d51a999dcbeae6c06223
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/208052
Reviewed-by: Dan Williams <dcbw@libreoffice.org>
Tested-by: Jenkins