diff options
Diffstat (limited to 'tests/Wallabag/UserBundle/Controller')
-rw-r--r-- | tests/Wallabag/UserBundle/Controller/ManageControllerTest.php | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/Wallabag/UserBundle/Controller/ManageControllerTest.php b/tests/Wallabag/UserBundle/Controller/ManageControllerTest.php index 247eb6ba..19b824b8 100644 --- a/tests/Wallabag/UserBundle/Controller/ManageControllerTest.php +++ b/tests/Wallabag/UserBundle/Controller/ManageControllerTest.php | |||
@@ -68,4 +68,15 @@ class ManageControllerTest extends WallabagCoreTestCase | |||
68 | // Check the user has been delete on the list | 68 | // Check the user has been delete on the list |
69 | $this->assertNotRegExp('/Foo User/', $client->getResponse()->getContent()); | 69 | $this->assertNotRegExp('/Foo User/', $client->getResponse()->getContent()); |
70 | } | 70 | } |
71 | |||
72 | public function testDeleteDisabledForLoggedUser() | ||
73 | { | ||
74 | $this->logInAs('admin'); | ||
75 | $client = $this->getClient(); | ||
76 | |||
77 | $crawler = $client->request('GET', '/users/'.$this->getLoggedInUserId().'/edit'); | ||
78 | $disabled = $crawler->selectButton('user.form.delete')->extract('disabled'); | ||
79 | |||
80 | $this->assertEquals('disabled', $disabled[0]); | ||
81 | } | ||
71 | } | 82 | } |