Sha256: 37a5136a1ced1f255eb318ed249f099767ff998d8331a35c9deb5cd42798917c

Contents?: true

Size: 627 Bytes

Versions: 43

Compression:

Stored size: 627 Bytes

Contents

// ========================================================================
// SC.UserDefaults Base Tests
// ========================================================================
/*globals module test ok isObj equals expects */

var obj; //global variables

module("User Defaults",{
 	   
 	  setup: function(){
 	   
 	   obj = SC.Object.create({
 		   bck : 'green'
 	    }); 	
 	}
});



test("To check if the user defaults are stored and read from local storage",function(){
    SC.userDefaults.writeDefault('Back',obj.bck);
    equals(SC.userDefaults.readDefault('Back'), obj.bck, 'should read written property');
});

Version data entries

43 entries across 43 versions & 3 rubygems

Version Path
sproutit-sproutcore-1.0.20090721145282 frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutit-sproutcore-1.0.20090721145285 frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
spade-0.0.1 sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.5.0.pre.5 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.5.0.pre.4.1 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.5.0.pre.4 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.5.0.pre.3 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.5 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.5-java lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.4-java lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.4 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.3.1 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.3-java lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.3 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.2-java lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.2 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.1-java lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.1 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.0-java lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js
sproutcore-1.4.0 lib/frameworks/sproutcore/frameworks/foundation/tests/system/user_defaults.js