This way it moves 73 more tests to unit tests Bug: T87781 Change-Id: I963488450bb355573d71ae31b57d71683ce51683
30 lines
485 B
PHP
30 lines
485 B
PHP
<?php
|
|
|
|
/**
|
|
* @covers Http
|
|
* @group Http
|
|
* @group small
|
|
*/
|
|
class HttpTest extends MediaWikiTestCase {
|
|
|
|
/**
|
|
* @covers Http::getProxy
|
|
*/
|
|
public function testGetProxy() {
|
|
$this->hideDeprecated( 'Http::getProxy' );
|
|
|
|
$this->setMwGlobals( 'wgHTTPProxy', false );
|
|
$this->assertEquals(
|
|
'',
|
|
Http::getProxy(),
|
|
'default setting'
|
|
);
|
|
|
|
$this->setMwGlobals( 'wgHTTPProxy', 'proxy.domain.tld' );
|
|
$this->assertEquals(
|
|
'proxy.domain.tld',
|
|
Http::getProxy()
|
|
);
|
|
}
|
|
|
|
}
|