/**
  * @dataProvider buildRegexpDataProvider
  * @param integer $expected
  * @param string $uri
  * @param string $hostname
  * @param string $path
  * @param integer $port
  * @param string $protocol
  * @param boolean $anyPort
  * @param boolean $anySubdomain
  */
 public function testBuildRegexp($expected, $uri, $hostname, $path, $port, $protocol, $anyPort, $anySubdomain)
 {
     $host = new Paysera_WalletApi_Entity_Client_Host();
     $host->setHost($hostname);
     $host->setPath($path);
     $host->setPort($port);
     $host->setProtocol($protocol);
     if ($anyPort) {
         $host->markAsAnyPort();
     }
     if ($anySubdomain) {
         $host->markAsAnySubdomain();
     }
     $this->assertSame($expected, preg_match($host->buildRegexp(), $uri));
 }