aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle
diff options
context:
space:
mode:
Diffstat (limited to 'src/Wallabag/CoreBundle')
-rw-r--r--src/Wallabag/CoreBundle/Resources/views/themes/material/Security/forgotPassword.html.twig5
-rw-r--r--src/Wallabag/CoreBundle/Tests/Controller/SecurityControllerTest.php19
2 files changed, 23 insertions, 1 deletions
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Security/forgotPassword.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Security/forgotPassword.html.twig
index 7d7fea6f..9750f8ba 100644
--- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Security/forgotPassword.html.twig
+++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Security/forgotPassword.html.twig
@@ -43,6 +43,9 @@
43 {{ form_rest(form) }} 43 {{ form_rest(form) }}
44 </form> 44 </form>
45 </div> 45 </div>
46 <div class="center">
47 <a href="{{ path('login') }}">{% trans %}Back to login{% endtrans %}</a>
48 </div>
46 </div> 49 </div>
47 </main> 50 </main>
48 <style> 51 <style>
@@ -53,4 +56,4 @@
53{% endblock %} 56{% endblock %}
54 57
55{% block footer %} 58{% block footer %}
56{% endblock %} \ No newline at end of file 59{% endblock %}
diff --git a/src/Wallabag/CoreBundle/Tests/Controller/SecurityControllerTest.php b/src/Wallabag/CoreBundle/Tests/Controller/SecurityControllerTest.php
index a51e836d..759ef01b 100644
--- a/src/Wallabag/CoreBundle/Tests/Controller/SecurityControllerTest.php
+++ b/src/Wallabag/CoreBundle/Tests/Controller/SecurityControllerTest.php
@@ -40,6 +40,25 @@ class SecurityControllerTest extends WallabagCoreTestCase
40 $this->assertContains('Bad credentials', $client->getResponse()->getContent()); 40 $this->assertContains('Bad credentials', $client->getResponse()->getContent());
41 } 41 }
42 42
43 public function testRedirectionAfterLogin()
44 {
45 $client = $this->getClient();
46 $client->followRedirects();
47
48 $crawler = $client->request('GET', '/config');
49
50 $form = $crawler->filter('button[type=submit]')->form();
51
52 $data = array(
53 '_username' => 'admin',
54 '_password' => 'mypassword',
55 );
56
57 $client->submit($form, $data);
58
59 $this->assertContains('RSS', $client->getResponse()->getContent());
60 }
61
43 public function testForgotPassword() 62 public function testForgotPassword()
44 { 63 {
45 $client = $this->getClient(); 64 $client = $this->getClient();