fix HostnamePort matches and new tests
Given / When & Then
compilation issue left behind
Merge pull request #2476 from giggluigg/fix-HostnamePort-matches

fix HostnamePort matches(URI) and new tests (ex #2453)