public function testLeague() { $api = new Api('key'); $league = $api->league(); $this->assertTrue($league instanceof LeagueWrap\Api\League); }
public function testChallenger() { $this->client->shouldReceive('baseUrl')->once(); $this->client->shouldReceive('request')->with('na/v2.5/league/challenger', ['api_key' => 'key', 'type' => 'RANKED_SOLO_5x5'])->once()->andReturn(file_get_contents('tests/Json/league.challenger.json')); $api = new Api('key', $this->client); $league = $api->league()->challenger(); $this->assertEquals(799, $league->entry('C9 Hai')->leaguePoints); }