Refactor access denied redirect.
Refactor tests and helpers.
Refactor tests. All tests success done.
Delete some comments.