Added optional second argument to `dispatcher.dispatch` to pass any static route params.
More tests fixes.