Sha256: 44e82402ee7bbee9d8d5c1cec41accea20fa02553b58838ff0c71501cb727eec

Contents?: true

Size: 850 Bytes

Versions: 47

Compression:

Stored size: 850 Bytes

Contents

// ========================================================================
// SC.makeArray Tests
// ========================================================================
/*globals module test */

var objectA,objectB,objectC; //global variables

module("Make Array ", {
  setup: function() {
    var objectA = [1,2,3,4,5] ;  
	var objectC = SC.hashFor(objectA);
	var objectD = null;
	var stringA = "string A" ;		
  }
});

test("should return an array for the object passed ",function(){
	var arrayA  = ['value1','value2'] ;
	var numberA = 100;
	var stringA = "SproutCore" ;
	var obj = {} ;
	var ret = SC.makeArray(obj);
	equals(SC.isArray(ret),true);	
	ret = SC.makeArray(stringA);
	equals(SC.isArray(ret), true) ;  	
	ret = SC.makeArray(numberA);
	equals(SC.isArray(ret),true) ;  	
	ret = SC.makeArray(arrayA);
	equals(SC.isArray(ret),true) ;
});

Version data entries

47 entries across 47 versions & 2 rubygems

Version Path
sproutit-sproutcore-1.0.0.20090720093355 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.0.20090720202429 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.0.20090721125122 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.126 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.20090721145251 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.20090721145280 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.20090721145281 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.20090721145282 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.20090721145285 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutit-sproutcore-1.0.203 frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.5.0.pre.3 lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.5 lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.5-java lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.4-java lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.4 lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.3.1 lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.3-java lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.3 lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.2-java lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js
sproutcore-1.4.2 lib/frameworks/sproutcore/frameworks/runtime/tests/core/makeArray.js