diff options
author | Thomas Citharel <tcit@tcit.fr> | 2016-09-21 19:24:19 +0200 |
---|---|---|
committer | Jeremy Benoist <jeremy.benoist@gmail.com> | 2016-09-25 12:29:19 +0200 |
commit | 64b1229b2d711e6b2f0e60de482802d9e86b912f (patch) | |
tree | ecf92f4cfd2eaecc9eb894f933222ccc0439e9f9 /src/Wallabag | |
parent | 2c61db30b737685ae9102ec10f2371778fb13f1a (diff) | |
download | wallabag-64b1229b2d711e6b2f0e60de482802d9e86b912f.tar.gz wallabag-64b1229b2d711e6b2f0e60de482802d9e86b912f.tar.zst wallabag-64b1229b2d711e6b2f0e60de482802d9e86b912f.zip |
fix tests
Diffstat (limited to 'src/Wallabag')
-rw-r--r-- | src/Wallabag/ImportBundle/Import/BrowserImport.php | 4 | ||||
-rw-r--r-- | src/Wallabag/ImportBundle/Import/ChromeImport.php | 40 | ||||
-rw-r--r-- | src/Wallabag/ImportBundle/Resources/config/redis.yml | 4 |
3 files changed, 24 insertions, 24 deletions
diff --git a/src/Wallabag/ImportBundle/Import/BrowserImport.php b/src/Wallabag/ImportBundle/Import/BrowserImport.php index 3e1cb12b..198e148e 100644 --- a/src/Wallabag/ImportBundle/Import/BrowserImport.php +++ b/src/Wallabag/ImportBundle/Import/BrowserImport.php | |||
@@ -31,13 +31,13 @@ abstract class BrowserImport extends AbstractImport | |||
31 | public function import() | 31 | public function import() |
32 | { | 32 | { |
33 | if (!$this->user) { | 33 | if (!$this->user) { |
34 | $this->logger->error('WallabagImport: user is not defined'); | 34 | $this->logger->error('Wallabag Browser Import: user is not defined'); |
35 | 35 | ||
36 | return false; | 36 | return false; |
37 | } | 37 | } |
38 | 38 | ||
39 | if (!file_exists($this->filepath) || !is_readable($this->filepath)) { | 39 | if (!file_exists($this->filepath) || !is_readable($this->filepath)) { |
40 | $this->logger->error('WallabagImport: unable to read file', ['filepath' => $this->filepath]); | 40 | $this->logger->error('Wallabag Browser Import: unable to read file', ['filepath' => $this->filepath]); |
41 | 41 | ||
42 | return false; | 42 | return false; |
43 | } | 43 | } |
diff --git a/src/Wallabag/ImportBundle/Import/ChromeImport.php b/src/Wallabag/ImportBundle/Import/ChromeImport.php index 941d68d3..1af7cc87 100644 --- a/src/Wallabag/ImportBundle/Import/ChromeImport.php +++ b/src/Wallabag/ImportBundle/Import/ChromeImport.php | |||
@@ -30,26 +30,26 @@ class ChromeImport extends BrowserImport | |||
30 | return 'import.chrome.description'; | 30 | return 'import.chrome.description'; |
31 | } | 31 | } |
32 | 32 | ||
33 | /** | 33 | /** |
34 | * {@inheritdoc} | 34 | * {@inheritdoc} |
35 | */ | 35 | */ |
36 | protected function prepareEntry($entry = []) | 36 | protected function prepareEntry($entry = []) |
37 | { | 37 | { |
38 | $data = [ | 38 | $data = [ |
39 | 'title' => $entry['name'], | 39 | 'title' => $entry['name'], |
40 | 'html' => '', | 40 | 'html' => '', |
41 | 'url' => $entry['url'], | 41 | 'url' => $entry['url'], |
42 | 'is_archived' => $this->markAsRead, | 42 | 'is_archived' => $this->markAsRead, |
43 | 'tags' => '', | 43 | 'tags' => '', |
44 | 'created_at' => $entry['date_added'], | 44 | 'created_at' => $entry['date_added'], |
45 | ]; | 45 | ]; |
46 | 46 | ||
47 | if (array_key_exists('tags', $entry) && $entry['tags'] != '') { | 47 | if (array_key_exists('tags', $entry) && $entry['tags'] != '') { |
48 | $data['tags'] = $entry['tags']; | 48 | $data['tags'] = $entry['tags']; |
49 | } | 49 | } |
50 | 50 | ||
51 | return $data; | 51 | return $data; |
52 | } | 52 | } |
53 | 53 | ||
54 | /** | 54 | /** |
55 | * {@inheritdoc} | 55 | * {@inheritdoc} |
diff --git a/src/Wallabag/ImportBundle/Resources/config/redis.yml b/src/Wallabag/ImportBundle/Resources/config/redis.yml index c47778b8..c9c2cf26 100644 --- a/src/Wallabag/ImportBundle/Resources/config/redis.yml +++ b/src/Wallabag/ImportBundle/Resources/config/redis.yml | |||
@@ -107,12 +107,12 @@ services: | |||
107 | - "@wallabag_core.redis.client" | 107 | - "@wallabag_core.redis.client" |
108 | - "wallabag.import.chrome" | 108 | - "wallabag.import.chrome" |
109 | 109 | ||
110 | wallabag_import.producer.redis.firefox: | 110 | wallabag_import.producer.redis.chrome: |
111 | class: Wallabag\ImportBundle\Redis\Producer | 111 | class: Wallabag\ImportBundle\Redis\Producer |
112 | arguments: | 112 | arguments: |
113 | - "@wallabag_import.queue.redis.chrome" | 113 | - "@wallabag_import.queue.redis.chrome" |
114 | 114 | ||
115 | wallabag_import.consumer.redis.firefox: | 115 | wallabag_import.consumer.redis.chrome: |
116 | class: Wallabag\ImportBundle\Consumer\RedisEntryConsumer | 116 | class: Wallabag\ImportBundle\Consumer\RedisEntryConsumer |
117 | arguments: | 117 | arguments: |
118 | - "@doctrine.orm.entity_manager" | 118 | - "@doctrine.orm.entity_manager" |