]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - tests/Wallabag/CoreBundle/Controller/SecurityControllerTest.php
Merge pull request #2416 from wallabag/2.2
[github/wallabag/wallabag.git] / tests / Wallabag / CoreBundle / Controller / SecurityControllerTest.php
index 03355f5abde2d02820ea5ce842c8938dccbe8dda..2cf596d46734eb43b8ecd327a61611ceff039a50 100644 (file)
@@ -69,4 +69,19 @@ class SecurityControllerTest extends WallabagCoreTestCase
         $this->assertTrue($user->isTrustedComputer('ABCDEF'));
         $this->assertFalse($user->isTrustedComputer('FEDCBA'));
     }
+
+    public function testEnabledRegistration()
+    {
+        $client = $this->getClient();
+
+        if (!$client->getContainer()->getParameter('fosuser_registration')) {
+            $this->markTestSkipped('fosuser_registration is not enabled.');
+
+            return;
+        }
+
+        $client->followRedirects();
+        $crawler = $client->request('GET', '/register');
+        $this->assertContains('registration.submit', $client->getResponse()->getContent());
+    }
 }