From 3b815d2de5a852fe2ebad5827bd4c9070aa175ea Mon Sep 17 00:00:00 2001 From: Jeremy Date: Sun, 8 Feb 2015 23:05:51 +0100 Subject: Add some fixtures Improve test, so user can login Fix some leftJoin Cleanup EntryController --- src/Wallabag/CoreBundle/Tests/WallabagTestCase.php | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 src/Wallabag/CoreBundle/Tests/WallabagTestCase.php (limited to 'src/Wallabag/CoreBundle/Tests/WallabagTestCase.php') diff --git a/src/Wallabag/CoreBundle/Tests/WallabagTestCase.php b/src/Wallabag/CoreBundle/Tests/WallabagTestCase.php new file mode 100644 index 00000000..5f092318 --- /dev/null +++ b/src/Wallabag/CoreBundle/Tests/WallabagTestCase.php @@ -0,0 +1,34 @@ +client; + } + + public function setUp() + { + $this->client = static::createClient(); + } + + public function logIn() + { + $crawler = $this->client->request('GET', '/login'); + $form = $crawler->filter('button[type=submit]')->form(); + $data = array( + '_username' => 'admin', + '_password' => 'test', + ); + + $this->client->submit($form, $data); + } +} -- cgit v1.2.3