function testGetNonEnglishRealm() { $client = Shared::Client(); $client->setRegion('eu'); $realm = $client->getRealmApi()->getRealm('Термоштепсель'); $this->assertNotEquals(false, $realm); $this->assertArrayHasKey('type', $realm); $this->assertArrayHasKey('queue', $realm); $this->assertArrayHasKey('status', $realm); $this->assertArrayHasKey('population', $realm); $this->assertArrayHasKey('name', $realm); $this->assertArrayHasKey('slug', $realm); }
/** * @expectedException WowApi\Exception\NotFoundException */ public function testSendToNonExistantResource() { $client = Shared::Client(); $response = $client->getRequest()->api('character/blank/blank'); $this->assertEquals(404, $response['headers']['http_code']); }
/** * @expectedException \InvalidArgumentException * @expectedExceptionMessage The locale `doesntExist` for region `us` is not supported. */ function testInvalidLocale() { $client = Shared::Client(); $client->setRegion('us', 'doesntExist'); }
protected function setUp() { $this->client = Shared::Client(); }
protected function setUp() { $this->api = Shared::Client()->getCharacterApi(); }
protected function setUp() { $this->api = Shared::Client()->getGuildApi(); }