Basho\Tests\Riak\Node\BuilderTest::testUsingAuth PHP Method

testUsingAuth() public method

public testUsingAuth ( )
    public function testUsingAuth()
    {
        $node = (new Builder())->atHost(static::getTestHost())->onPort(static::getTestSecurePort())->usingPasswordAuthentication('unauthorizeduser', 'hispassword')->withCertificateAuthorityFile(getcwd() . '/tools/test-ca/certs/cacert.pem')->build();
        $riak = new Riak([$node]);
        $this->assertEquals('unauthorizeduser', $node->getUserName());
        $this->assertEquals('hispassword', $node->getPassword());
        $this->assertEquals(getcwd() . '/tools/test-ca/certs/cacert.pem', $node->getCaFile());
        $this->assertInstanceOf('Basho\\Riak', $riak);
    }