]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/CoreBundle/Tests/Controller/TagControllerTest.php
Convert english translation file
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Tests / Controller / TagControllerTest.php
index ae29a2a68383016de785d2957fee8b6c83dcae7a..338121e7e1312a13144afbd69961566aaaa13919 100644 (file)
@@ -30,7 +30,7 @@ class TagControllerTest extends WallabagCoreTestCase
 
         $crawler = $client->request('GET', '/view/'.$entry->getId());
 
-        $form = $crawler->filter('button[id=tag_save]')->form();
+        $form = $crawler->filter('form[name=tag]')->form();
 
         $data = array(
             'tag[label]' => $this->tagName,
@@ -81,12 +81,14 @@ class TagControllerTest extends WallabagCoreTestCase
         $tag = $client->getContainer()
             ->get('doctrine.orm.entity_manager')
             ->getRepository('WallabagCoreBundle:Tag')
-            ->findOnebyEntryAndLabel($entry, $this->tagName);
+            ->findOneByEntryAndTagLabel($entry, $this->tagName);
 
         $client->request('GET', '/remove-tag/'.$entry->getId().'/'.$tag->getId());
 
         $this->assertEquals(302, $client->getResponse()->getStatusCode());
 
+        $this->assertNotContains($this->tagName, $entry->getTags());
+
         $client->request('GET', '/remove-tag/'.$entry->getId().'/'.$tag->getId());
 
         $this->assertEquals(404, $client->getResponse()->getStatusCode());