[#3711] Fix regression in query string matching

If a route is marked may_terminate, and a query string is present, in
most cases, we should match; the query route is primarily for the
convenience of _generating_ URIs via the assemble() method, and only
matches if a query string is present.

This patch adds tests that do the following:

- If the route is marked may_terminate and a query string is present,
  but there is no Query route child, match and return immediately.
- If the route is marked may_terminate, and a query string is present,
  and a Query route child is present, pass matching on to child routes.
Merge branch 'hotfix/3711' of git://github.com/weierophinney/zf2 into weierophinney-hotfix/3711
Closes #3778
Also closes #3711
Also closes #3652
Also closes #3636

Merge branch 'weierophinney-hotfix/3711'