blob: a8d3a0f760723954e54235e1a66b24fa8f91dbf2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
/**
* ownCloud - News
*
* This file is licensed under the Affero General Public License version 3 or
* later. See the COPYING file.
*
* @author Bernhard Posselt <dev@bernhard-posselt.com>
* @copyright Bernhard Posselt 2014
*/
describe('NavigationController', () => {
'use strict';
let controller;
beforeEach(module('News', ($provide) => {
$provide.value('BASE_URL', 'base');
}));
beforeEach(inject(($controller) => {
controller = $controller('NavigationController');
}));
it('should expose Feeds', inject((FeedResource) => {
FeedResource.add({url: 1});
expect(controller.getFeeds()).toBe(FeedResource.getAll());
}));
it('should expose Folders', inject((FolderResource) => {
FolderResource.add({name: 1});
expect(controller.getFolders()).toBe(FolderResource.getAll());
}));
});
|