File tree Expand file tree Collapse file tree 1 file changed +41
-0
lines changed
Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Original file line number Diff line number Diff line change @@ -55,3 +55,44 @@ describe('Tests for SettingsStore', function () {
5555 } ) ;
5656
5757} ) ;
58+
59+
60+ describe ( 'Tests for SettingsStore' , function ( ) {
61+
62+ var SettingsStore , Actions ;
63+
64+ beforeEach ( function ( ) {
65+
66+ // Mock Electron's window.require
67+ window . require = function ( ) {
68+ return {
69+ sendChannel : function ( ) {
70+ return ;
71+ }
72+ } ;
73+ } ;
74+
75+ // Mock localStorage
76+ window . localStorage = {
77+ item : false ,
78+ getItem : function ( ) {
79+ return '{}' ;
80+ } ,
81+ setItem : function ( item ) {
82+ this . item = item ;
83+ }
84+ } ;
85+
86+ Actions = require ( '../../actions/actions.js' ) ;
87+ SettingsStore = require ( '../../stores/settings.js' ) ;
88+ } ) ;
89+
90+ it ( 'should get the settings as string' , function ( ) {
91+
92+ spyOn ( SettingsStore , 'trigger' ) ;
93+
94+ SettingsStore . getSettings ( ) ;
95+
96+ } ) ;
97+
98+ } ) ;
You can’t perform that action at this time.
0 commit comments