Files
piratepoet/tests/unit/Util/UrlTest.php
Jan Jakeš 0dcdf6e9f1 Autofix line endings
[MAILPOET-2715]
2020-02-19 19:12:53 +00:00

20 lines
480 B
PHP

<?php
namespace MailPoet\Test\Util;
use Codeception\Stub;
use MailPoet\Util\Url;
use MailPoet\WP\Functions as WPFunctions;
class UrlTest extends \MailPoetUnitTest {
public function testCurrentUrlReturnsHomeUrlOnHome() {
$homeUrl = 'http://example.com';
$urlHelper = new Url(Stub::make(new WPFunctions(), [
'homeUrl' => $homeUrl,
'addQueryArg' => '',
]));
$currentUrl = $urlHelper->getCurrentUrl();
expect($currentUrl)->equals($homeUrl);
}
}