tls: fix installed tests differently

The previous patch worked for "make check" and for running the
installed tests, but failed when running tests by hand, because
G_TEST_SRCDIR wouldn't be set, so it would just use "./", and then
GFileDatabase would complain that you had passed it a relative path.

Re-fix by adding a helper method to force-absolutify the paths, if
needed. (Also, intern the path names to avoid needed all the g_free()s
from the previous patch.)