mirror of
https://github.com/wallabag/wallabag.git
synced 2025-08-01 17:38:38 +00:00
Add build test on PHP 8.0 & 8.1
Add `isTransactional` to `WallabagMigration` because PHP 8 behave differently with PDO transaction. This is a workaround because we can't upgrade Doctrine Migration for now (upper versions have the fix). - Build is now using Composer v2 (instead of v1) - All actions have been updated to latest version - Fix bug in PHP 8 were `$entry->getTags()` can't be properly used as a _traversable_ by `assertContains` during tests. Added a custom method `Entry::getTagsLabel()` which return a flatted tag array with only label - Replace `assertNotRegExp` by `assertDoesNotMatchRegularExpression` because it was deprecated
This commit is contained in:
parent
6aeaaaabdd
commit
3c507d676f
15 changed files with 48 additions and 23 deletions
|
@ -123,7 +123,7 @@ class InstapaperControllerTest extends WallabagCoreTestCase
|
|||
$this->assertNotEmpty($content->getMimetype(), 'Mimetype for https://www.liberation.fr is ok');
|
||||
$this->assertNotEmpty($content->getPreviewPicture(), 'Preview picture for https://www.liberation.fr is ok');
|
||||
$this->assertNotEmpty($content->getLanguage(), 'Language for https://www.liberation.fr is ok');
|
||||
$this->assertContains('foot', $content->getTags(), 'It includes the "foot" tag');
|
||||
$this->assertContains('foot', $content->getTagsLabel(), 'It includes the "foot" tag');
|
||||
$this->assertCount(1, $content->getTags());
|
||||
$this->assertInstanceOf(\DateTime::class, $content->getCreatedAt());
|
||||
|
||||
|
@ -135,8 +135,8 @@ class InstapaperControllerTest extends WallabagCoreTestCase
|
|||
$this->getLoggedInUserId()
|
||||
);
|
||||
|
||||
$this->assertContains('foot', $content->getTags());
|
||||
$this->assertContains('test_tag', $content->getTags());
|
||||
$this->assertContains('foot', $content->getTagsLabel());
|
||||
$this->assertContains('test_tag', $content->getTagsLabel());
|
||||
|
||||
$this->assertCount(2, $content->getTags());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue