Enable test for a non-default database

This change enables a test of the ability to use a redis database other
than the default (0). Because data is stored in a serialised form the
returned value is 'scrubbed' to remove any characters that would be
invalid for a string comparison, allowing the test to use a simple
match to check for the expected stored string.

The change also renames the 'location' variable in tomcat_helper to
resolve a variable name conflict.

[#64604732]
Merge branch 'default-database'