Skip to content
This repository was archived by the owner on Jan 31, 2020. It is now read-only.

Commit 3383c18

Browse files
mtagliabmichalbundyra
authored andcommitted
Added test to check colon is correctly removed
1 parent df8828e commit 3383c18

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/UriTest.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1371,4 +1371,14 @@ public function testReservedCharsInPathUnencoded()
13711371
$uri->toString()
13721372
);
13731373
}
1374+
1375+
public function testUriWithEndingColonWithoutPort()
1376+
{
1377+
$uriString = 'http://www.example.com:';
1378+
$uri = new Uri($uriString);
1379+
1380+
$this->assertSame($uri->getHost(), 'www.example.com');
1381+
$this->assertSame($uri->getPort(), null);
1382+
1383+
}
13741384
}

0 commit comments

Comments
 (0)