summaryrefslogtreecommitdiffstats
path: root/js/tests/unit/service/SettingsSpec.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/tests/unit/service/SettingsSpec.js')
-rw-r--r--js/tests/unit/service/SettingsSpec.js30
1 files changed, 30 insertions, 0 deletions
diff --git a/js/tests/unit/service/SettingsSpec.js b/js/tests/unit/service/SettingsSpec.js
new file mode 100644
index 000000000..65dc4bf2f
--- /dev/null
+++ b/js/tests/unit/service/SettingsSpec.js
@@ -0,0 +1,30 @@
+/**
+ * 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('Settings', function () {
+ 'use strict';
+
+ beforeEach(module('News'));
+
+ it('should receive default settings', inject(function (Settings) {
+ Settings.receive({
+ 'showAll': true
+ });
+
+ expect(Settings.get('showAll')).toBe(true);
+ }));
+
+
+ it('should set values', inject(function (Settings) {
+ Settings.set('showAll', true);
+
+ expect(Settings.get('showAll')).toBe(true);
+ }));
+
+}); \ No newline at end of file