mirror of https://github.com/wallabag/wallabag.git
Merge pull request #6812 from yguedidi/make-crawler-extract-get-an-array
Make Crawler::extract get an array
This commit is contained in:
commit
0ccbd653fa
|
@ -1654,7 +1654,7 @@ class EntryControllerTest extends WallabagCoreTestCase
|
||||||
// As long as the deletion link of a tag is following
|
// As long as the deletion link of a tag is following
|
||||||
// a link to the tag view, we take the second one to retrieve
|
// a link to the tag view, we take the second one to retrieve
|
||||||
// the deletion link of the first tag
|
// the deletion link of the first tag
|
||||||
$link = $crawler->filter('body div#article div.tools ul.tags li.chip a')->extract('href')[1];
|
$link = $crawler->filter('body div#article div.tools ul.tags li.chip a')->extract(['href'])[1];
|
||||||
|
|
||||||
$this->assertSame(sprintf('/remove-tag/%s/%s', $entry->getId(), $tag->getId()), $link);
|
$this->assertSame(sprintf('/remove-tag/%s/%s', $entry->getId(), $tag->getId()), $link);
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,7 +74,7 @@ class ManageControllerTest extends WallabagCoreTestCase
|
||||||
$client = $this->getTestClient();
|
$client = $this->getTestClient();
|
||||||
|
|
||||||
$crawler = $client->request('GET', '/users/' . $this->getLoggedInUserId() . '/edit');
|
$crawler = $client->request('GET', '/users/' . $this->getLoggedInUserId() . '/edit');
|
||||||
$disabled = $crawler->selectButton('user.form.delete')->extract('disabled');
|
$disabled = $crawler->selectButton('user.form.delete')->extract(['disabled']);
|
||||||
|
|
||||||
$this->assertSame('disabled', $disabled[0]);
|
$this->assertSame('disabled', $disabled[0]);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue