discover() public méthode

Performs Yadis and HTML discovery.
public discover ( string $url ) : array
$url string Identity URL.
Résultat array OpenID provider info, following keys will be available: - url: string, OP Endpoint (i.e. OpenID provider address). - version: int, OpenID protocol version used by provider. - identity: string, identity value. - identifier_select: bool, whether to request OP to select identity for an user in OpenID 2, does not affect OpenID 1. - ax: bool, whether AX attributes should be used. - sreg: bool, whether SREG attributes should be used.
 public function testDiscover()
 {
     $url = 'https://www.google.com/accounts/o8/id';
     $client = new OpenId();
     $info = $client->discover($url);
     $this->assertNotEmpty($info);
     $this->assertNotEmpty($info['url']);
     $this->assertNotEmpty($info['identity']);
     $this->assertEquals(2, $info['version']);
     $this->assertArrayHasKey('identifier_select', $info);
     $this->assertArrayHasKey('ax', $info);
     $this->assertArrayHasKey('sreg', $info);
 }