unify null checks - avoid method call in favor of strict check
simplyfy test and correct some test param orders
a few more orders in test case corrected
RedirectRoute class does not honor persist as array with custom route elements.

Custom route elements like '/:lang/etc' should be persisted by redirect
routes as they are in standard routes.

Refs #GH-1531
Merge pull request #1533 from dereuromark/master-null-checks

unify null checks - avoid method call in favor of strict check
Add a test for Hash::sort()

Closes #3956