web3.php/test/unit/RequestManagerTest.php
2018-02-21 10:48:45 +08:00

26 lines
689 B
PHP

<?php
namespace Test\Unit;
use Test\TestCase;
use Web3\RequestManagers\RequestManager;
class RequestManagerTest extends TestCase
{
/**
* testSetHost
*
* @return void
*/
public function testSetHost()
{
$requestManager = new RequestManager('http://localhost:8545', 0.1);
$this->assertEquals($requestManager->host, 'http://localhost:8545');
$this->assertEquals($requestManager->timeout, 0.1);
$requestManager->host = $this->testRinkebyHost;
$requestManager->timeout = 1;
$this->assertEquals($requestManager->host, 'http://localhost:8545');
$this->assertEquals($requestManager->timeout, 0.1);
}
}