Interactive page to debug tests

Add an in interactive page that can be used to easily debug tests of any test-type.

`BaseTestType` now has an additional parameter, `debug` that is specified links to this interactive page.

To do so, this commit introduces generic middlewares.