Skip to content

Meson test environment setup fixes

commit 3ce290f6:

tests: pick up rtsp-server plugins from build directory only

commit 3051c965:

tests: gst-plugins-base and -bad plugins are required for the unit tests
Make hard requirement until we have more fine-grained control
in the unit tests. Of course the presence of the .pc file doesn't
imply that the plugins we need are actually there, but it's at
least a step in the right direction.

commit 80358ba1:

tests: fix meson test env setup to make sure we use the right gst-plugin-scanner
If core is built as a subproject (e.g. as in gst-build), make sure to use
the gst-plugin-scanner from the built subproject. Without this, gstreamer
might accidentally use the gst-plugin-scanner from the install prefix if
that exists, which in turn might drag in gst library versions we didn't
mean to drag in. Those gst library versions might then be older than
what our current build needs, and might cause our newly-built plugins
to get blacklisted in the test registry because they rely on a symbol
that the wrongly-pulled in gst lib doesn't have.

This should fix running of unit tests in gst-build when invoking
meson test or ninja test from outside the devenv for the case where
there is an older or different-version gst-plugin-scanner installed
in the install prefix.

In case no gst-plugin-scanner is installed in the install prefix, this
will fix "GStreamer-WARNING: External plugin loader failed. This most
likely means that the plugin loader helper binary was not found or
could not be run. You might need to set the GST_PLUGIN_SCANNER
environment variable if your setup is unusual." warnings when running
the unit tests.

In the case where we find GStreamer core via pkg-config we use
a newly-added pkg-config var "pluginscannerdir" to get the right
directory. This has the benefit of working transparently for both
installed and uninstalled pkg-config files/setups.

commit 511d07a4:

tests: put registry into tests/check not the gst/ subdir
Underscorify the test name before setting GST_REGISTRY,
so the registry actually ends up in the current build dir
and not some subdir.

For consistency with the other modules, but should also
avoid problems on windows.

Also fix indentation of environment block.

Merge request reports