forked from wallabag/wallabag
Merge remote-tracking branch 'origin/master' into 2.5.0
This commit is contained in:
@@ -207,8 +207,8 @@ class EntryControllerTest extends WallabagCoreTestCase
|
||||
$authors = $content->getPublishedBy();
|
||||
$this->assertSame('2017-04-05', $content->getPublishedAt()->format('Y-m-d'));
|
||||
$this->assertSame('fr', $content->getLanguage());
|
||||
$this->assertContains('Balenieri', $authors[0]);
|
||||
$this->assertContains('Autran', $authors[1]);
|
||||
$this->assertStringContainsString('Balenieri', $authors[0]);
|
||||
$this->assertStringContainsString('Autran', $authors[1]);
|
||||
}
|
||||
|
||||
public function testPostNewOkUrlExist()
|
||||
@@ -342,7 +342,7 @@ class EntryControllerTest extends WallabagCoreTestCase
|
||||
$entry = $em
|
||||
->getRepository('WallabagCoreBundle:Entry')
|
||||
->findOneByUrl($url);
|
||||
$tags = $entry->getTags();
|
||||
$tags = $entry->getTagsLabel();
|
||||
|
||||
$this->assertCount(2, $tags);
|
||||
$this->assertContains('wallabag', $tags);
|
||||
@@ -372,7 +372,7 @@ class EntryControllerTest extends WallabagCoreTestCase
|
||||
->getRepository('WallabagCoreBundle:Entry')
|
||||
->findOneByUrl($url);
|
||||
|
||||
$tags = $entry->getTags();
|
||||
$tags = $entry->getTagsLabel();
|
||||
|
||||
$this->assertCount(2, $tags);
|
||||
$this->assertContains('wallabag', $tags);
|
||||
@@ -1387,7 +1387,7 @@ class EntryControllerTest extends WallabagCoreTestCase
|
||||
{
|
||||
return [
|
||||
'ru' => [
|
||||
'https://www.vtimes.io/2020/12/14/ubiistvo-kotorogo-ne-bilo-a1981',
|
||||
'https://ru.wikipedia.org/wiki/Открытое_программное_обеспечение',
|
||||
'ru',
|
||||
],
|
||||
'fr' => [
|
||||
@@ -1410,10 +1410,6 @@ class EntryControllerTest extends WallabagCoreTestCase
|
||||
'https://politica.estadao.com.br/noticias/eleicoes,campanha-catatonica,70002491983',
|
||||
'pt_BR',
|
||||
],
|
||||
'fucked_list_of_languages' => [
|
||||
'http://geocatalog.webservice-energy.org/geonetwork/srv/eng/main.home',
|
||||
null,
|
||||
],
|
||||
'es-ES' => [
|
||||
'https://www.20minutos.es/noticia/3360685/0/gobierno-sanchez-primero-historia-mas-mujeres-que-hombres/',
|
||||
'es_ES',
|
||||
|
||||
@@ -46,7 +46,7 @@ class TagControllerTest extends WallabagCoreTestCase
|
||||
// be sure to reload the entry
|
||||
$entry = $this->getEntityManager()->getRepository(Entry::class)->find($entry->getId());
|
||||
$this->assertCount(1, $entry->getTags());
|
||||
$this->assertContains($this->tagName, $entry->getTags());
|
||||
$this->assertContains($this->tagName, $entry->getTagsLabel());
|
||||
|
||||
// tag already exists and already assigned
|
||||
$client->submit($form, $data);
|
||||
@@ -127,7 +127,7 @@ class TagControllerTest extends WallabagCoreTestCase
|
||||
|
||||
// re-retrieve the entry to be sure to get fresh data from database (mostly for tags)
|
||||
$entry = $this->getEntityManager()->getRepository(Entry::class)->find($entry->getId());
|
||||
$this->assertNotContains($this->tagName, $entry->getTags());
|
||||
$this->assertNotContains($this->tagName, $entry->getTagsLabel());
|
||||
|
||||
$client->request('GET', '/remove-tag/' . $entry->getId() . '/' . $tag->getId());
|
||||
|
||||
@@ -195,7 +195,7 @@ class TagControllerTest extends WallabagCoreTestCase
|
||||
$entry2 = new Entry($this->getLoggedInUser());
|
||||
$entry2->setUrl('http://0.0.0.0/bar');
|
||||
$entry2->addTag($tag);
|
||||
$this->getEntityManager()->persist($entry);
|
||||
$this->getEntityManager()->persist($entry2);
|
||||
|
||||
$this->getEntityManager()->flush();
|
||||
$this->getEntityManager()->clear();
|
||||
|
||||
Reference in New Issue
Block a user