Skip to content

Commit

Permalink
Added some more tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Brecht-Precht committed Jul 11, 2016
1 parent f040c1b commit a2e8346
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 49 deletions.
49 changes: 0 additions & 49 deletions test.php

This file was deleted.

11 changes: 11 additions & 0 deletions test/UrlTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,17 @@ public function testParser()
$expected = 'http://doe:[email protected]:8080/path/to/another/resource?arg1=456&arg3=test#target';
$this->assertEquals($expected, $url->buildUrl());

$url->clearQueryParameters();
$this->assertFalse($url->hasQueryParameters());

$url->setQueryParametersFromArray(array(
'arg1' => 1,
'arg2' => 2
));

$this->assertTrue($url->hasQueryParameters());
$this->assertEquals(2, $url->countQueryParameters());

}

}

0 comments on commit a2e8346

Please sign in to comment.