Add new test for 301 redirect

Simple unit test to check 301 redirects still work with the changes I made in https://github.com/joomla/joomla-cms/pull/4292