public function testWithHostForSameUppercaseHost() { $uri = new Uri('https://*****:*****@local.example.com:3001/foo?bar=baz#quz'); $new = $uri->withHost('LOCAL.EXAMPLE.COM'); $this->assertNotSame($uri, $new); $this->assertEquals('local.example.com', $new->getHost()); $this->assertEquals('https://*****:*****@local.example.com:3001/foo?bar=baz#quz', (string) $new); }