aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2016-09-11 20:24:04 +0200
committerJeremy Benoist <jeremy.benoist@gmail.com>2016-09-11 22:15:31 +0200
commit015c7a8359c950f9621b38b11c3973860a981da8 (patch)
treec9564ff38242df100e19f2de77d8d640599c0ea2 /tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php
parent7d862f83b95d24b4f081d73ca7b0bdf4435ae008 (diff)
downloadwallabag-015c7a8359c950f9621b38b11c3973860a981da8.tar.gz
wallabag-015c7a8359c950f9621b38b11c3973860a981da8.tar.zst
wallabag-015c7a8359c950f9621b38b11c3973860a981da8.zip
Add more tests
And ability to define how many messages can be hanle by the redis worker before stopping (usefull for tests)
Diffstat (limited to 'tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php')
-rw-r--r--tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php b/tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php
index 69635382..fb835f62 100644
--- a/tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php
+++ b/tests/Wallabag/ImportBundle/Controller/ReadabilityControllerTest.php
@@ -51,6 +51,23 @@ class ReadabilityControllerTest extends WallabagCoreTestCase
51 $client->getContainer()->get('craue_config')->set('import_with_redis', 0); 51 $client->getContainer()->get('craue_config')->set('import_with_redis', 0);
52 } 52 }
53 53
54 public function testImportReadabilityBadFile()
55 {
56 $this->logInAs('admin');
57 $client = $this->getClient();
58
59 $crawler = $client->request('GET', '/import/readability');
60 $form = $crawler->filter('form[name=upload_import_file] > button[type=submit]')->form();
61
62 $data = [
63 'upload_import_file[file]' => '',
64 ];
65
66 $client->submit($form, $data);
67
68 $this->assertEquals(200, $client->getResponse()->getStatusCode());
69 }
70
54 public function testImportReadabilityWithFile() 71 public function testImportReadabilityWithFile()
55 { 72 {
56 $this->logInAs('admin'); 73 $this->logInAs('admin');