@@ -3136,8 +3136,8 @@ describe('lib/optimizely', function() {
31363136 } ) ;
31373137 } ) ;
31383138
3139- it ( 'returns the right value from getFeatureVariableJson and send notification with featureEnabled true' , function ( ) {
3140- var result = optlyInstance . getFeatureVariableJson (
3139+ it ( 'returns the right value from getFeatureVariableJSON and send notification with featureEnabled true' , function ( ) {
3140+ var result = optlyInstance . getFeatureVariableJSON (
31413141 'test_feature_for_experiment' ,
31423142 'button_info' ,
31433143 'user1' ,
@@ -3334,8 +3334,8 @@ describe('lib/optimizely', function() {
33343334 } ) ;
33353335 } ) ;
33363336
3337- it ( 'returns the default value from getFeatureVariableJson and send notification with featureEnabled false' , function ( ) {
3338- var result = optlyInstance . getFeatureVariableJson (
3337+ it ( 'returns the default value from getFeatureVariableJSON and send notification with featureEnabled false' , function ( ) {
3338+ var result = optlyInstance . getFeatureVariableJSON (
33393339 'test_feature_for_experiment' ,
33403340 'button_info' ,
33413341 'user1' ,
@@ -3621,8 +3621,8 @@ describe('lib/optimizely', function() {
36213621 } ) ;
36223622 } ) ;
36233623
3624- it ( 'should return the right value from getFeatureVariableJson and send notification with featureEnabled true' , function ( ) {
3625- var result = optlyInstance . getFeatureVariableJson ( 'test_feature' , 'message_info' , 'user1' , {
3624+ it ( 'should return the right value from getFeatureVariableJSON and send notification with featureEnabled true' , function ( ) {
3625+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature' , 'message_info' , 'user1' , {
36263626 test_attribute : 'test_value' ,
36273627 } ) ;
36283628 assert . deepEqual ( result , {
@@ -3894,8 +3894,8 @@ describe('lib/optimizely', function() {
38943894 } ) ;
38953895 } ) ;
38963896
3897- it ( 'should return the default value from getFeatureVariableJson and send notification with featureEnabled false' , function ( ) {
3898- var result = optlyInstance . getFeatureVariableJson ( 'test_feature' , 'message_info' , 'user1' , {
3897+ it ( 'should return the default value from getFeatureVariableJSON and send notification with featureEnabled false' , function ( ) {
3898+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature' , 'message_info' , 'user1' , {
38993899 test_attribute : 'test_value' ,
39003900 } ) ;
39013901 assert . deepEqual ( result , {
@@ -4181,8 +4181,8 @@ describe('lib/optimizely', function() {
41814181 } ) ;
41824182 } ) ;
41834183
4184- it ( 'returns the variable default value from getFeatureVariableJson and send notification with featureEnabled false' , function ( ) {
4185- var result = optlyInstance . getFeatureVariableJson (
4184+ it ( 'returns the variable default value from getFeatureVariableJSON and send notification with featureEnabled false' , function ( ) {
4185+ var result = optlyInstance . getFeatureVariableJSON (
41864186 'test_feature_for_experiment' ,
41874187 'button_info' ,
41884188 'user1' ,
@@ -5065,8 +5065,8 @@ describe('lib/optimizely', function() {
50655065 ) ;
50665066 } ) ;
50675067
5068- it ( 'returns the right value from getFeatureVariableJson ' , function ( ) {
5069- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_info' , 'user1' , {
5068+ it ( 'returns the right value from getFeatureVariableJSON ' , function ( ) {
5069+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_info' , 'user1' , {
50705070 test_attribute : 'test_value' ,
50715071 } ) ;
50725072 assert . deepEqual ( result , {
@@ -5252,8 +5252,8 @@ describe('lib/optimizely', function() {
52525252 ) ;
52535253 } ) ;
52545254
5255- it ( 'returns the variable default value from getFeatureVariableJson ' , function ( ) {
5256- var result = optlyInstance . getFeatureVariableJson (
5255+ it ( 'returns the variable default value from getFeatureVariableJSON ' , function ( ) {
5256+ var result = optlyInstance . getFeatureVariableJSON (
52575257 'test_feature_for_experiment' ,
52585258 'button_info' ,
52595259 'user1' ,
@@ -5450,8 +5450,8 @@ describe('lib/optimizely', function() {
54505450 ) ;
54515451 } ) ;
54525452
5453- it ( 'returns the variable default value from getFeatureVariableJson ' , function ( ) {
5454- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_info' , 'user1' , {
5453+ it ( 'returns the variable default value from getFeatureVariableJSON ' , function ( ) {
5454+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_info' , 'user1' , {
54555455 test_attribute : 'test_value' ,
54565456 } ) ;
54575457 assert . deepEqual ( result , {
@@ -5634,8 +5634,8 @@ describe('lib/optimizely', function() {
56345634 ) ;
56355635 } ) ;
56365636
5637- it ( 'returns the right value from getFeatureVariableJson ' , function ( ) {
5638- var result = optlyInstance . getFeatureVariableJson ( 'test_feature' , 'message_info' , 'user1' , {
5637+ it ( 'returns the right value from getFeatureVariableJSON ' , function ( ) {
5638+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature' , 'message_info' , 'user1' , {
56395639 test_attribute : 'test_value' ,
56405640 } ) ;
56415641 assert . deepEqual ( result , {
@@ -5806,8 +5806,8 @@ describe('lib/optimizely', function() {
58065806 ) ;
58075807 } ) ;
58085808
5809- it ( 'returns the variable default value from getFeatureVariableJson ' , function ( ) {
5810- var result = optlyInstance . getFeatureVariableJson ( 'test_feature' , 'message_info' , 'user1' , {
5809+ it ( 'returns the variable default value from getFeatureVariableJSON ' , function ( ) {
5810+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature' , 'message_info' , 'user1' , {
58115811 test_attribute : 'test_value' ,
58125812 } ) ;
58135813 assert . deepEqual ( result , {
@@ -5989,8 +5989,8 @@ describe('lib/optimizely', function() {
59895989 ) ;
59905990 } ) ;
59915991
5992- it ( 'returns the variable default value from getFeatureVariableJson ' , function ( ) {
5993- var result = optlyInstance . getFeatureVariableJson ( 'test_feature' , 'message_info' , 'user1' , {
5992+ it ( 'returns the variable default value from getFeatureVariableJSON ' , function ( ) {
5993+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature' , 'message_info' , 'user1' , {
59945994 test_attribute : 'test_value' ,
59955995 } ) ;
59965996 assert . deepEqual ( result , {
@@ -6170,8 +6170,8 @@ describe('lib/optimizely', function() {
61706170 ) ;
61716171 } ) ;
61726172
6173- it ( 'returns the variable default value from getFeatureVariableJson ' , function ( ) {
6174- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_info' , 'user1' , {
6173+ it ( 'returns the variable default value from getFeatureVariableJSON ' , function ( ) {
6174+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_info' , 'user1' , {
61756175 test_attribute : 'test_value' ,
61766176 } ) ;
61776177 assert . deepEqual ( result , {
@@ -6441,8 +6441,8 @@ describe('lib/optimizely', function() {
64416441 ) ;
64426442 } ) ;
64436443
6444- it ( 'returns null from getFeatureVariableJson when called with a non-json variable' , function ( ) {
6445- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_txt' , 'user1' ) ;
6444+ it ( 'returns null from getFeatureVariableJSON when called with a non-json variable' , function ( ) {
6445+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_txt' , 'user1' ) ;
64466446 assert . strictEqual ( result , null ) ;
64476447 sinon . assert . calledWith (
64486448 createdLogger . log ,
@@ -6593,8 +6593,8 @@ describe('lib/optimizely', function() {
65936593 ) ;
65946594 } ) ;
65956595
6596- it ( 'returns null from getFeatureVariableJson if user id is null' , function ( ) {
6597- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_info' , null , {
6596+ it ( 'returns null from getFeatureVariableJSON if user id is null' , function ( ) {
6597+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_info' , null , {
65986598 test_attribute : 'test_value' ,
65996599 } ) ;
66006600 assert . strictEqual ( result , null ) ;
@@ -6605,8 +6605,8 @@ describe('lib/optimizely', function() {
66056605 ) ;
66066606 } ) ;
66076607
6608- it ( 'returns null from getFeatureVariableJson if user id is undefined' , function ( ) {
6609- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_info' , undefined , {
6608+ it ( 'returns null from getFeatureVariableJSON if user id is undefined' , function ( ) {
6609+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_info' , undefined , {
66106610 test_attribute : 'test_value' ,
66116611 } ) ;
66126612 assert . strictEqual ( result , null ) ;
@@ -6617,8 +6617,8 @@ describe('lib/optimizely', function() {
66176617 ) ;
66186618 } ) ;
66196619
6620- it ( 'returns null from getFeatureVariableJson if user id is not provided' , function ( ) {
6621- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_info' ) ;
6620+ it ( 'returns null from getFeatureVariableJSON if user id is not provided' , function ( ) {
6621+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_info' ) ;
66226622 assert . strictEqual ( result , null ) ;
66236623 sinon . assert . calledWith (
66246624 createdLogger . log ,
@@ -6686,7 +6686,7 @@ describe('lib/optimizely', function() {
66866686 } ) ;
66876687
66886688 it ( 'should return null and log an error' , function ( ) {
6689- var result = optlyInstance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'button_info' , 'user1' ) ;
6689+ var result = optlyInstance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'button_info' , 'user1' ) ;
66906690 assert . strictEqual ( result , null ) ;
66916691 sinon . assert . calledWith (
66926692 createdLogger . log ,
@@ -6801,8 +6801,8 @@ describe('lib/optimizely', function() {
68016801 ) ;
68026802 } ) ;
68036803
6804- it ( 'returns null from getFeatureVariableJson if the argument feature key is invalid' , function ( ) {
6805- var result = optlyInstance . getFeatureVariableJson ( 'thisIsNotAValidKey<><><>' , 'button_info' , 'user1' ) ;
6804+ it ( 'returns null from getFeatureVariableJSON if the argument feature key is invalid' , function ( ) {
6805+ var result = optlyInstance . getFeatureVariableJSON ( 'thisIsNotAValidKey<><><>' , 'button_info' , 'user1' ) ;
68066806 assert . strictEqual ( result , null ) ;
68076807 sinon . assert . calledWith (
68086808 createdLogger . log ,
@@ -6867,8 +6867,8 @@ describe('lib/optimizely', function() {
68676867 ) ;
68686868 } ) ;
68696869
6870- it ( 'returns null from getFeatureVariableJson if the argument variable key is invalid' , function ( ) {
6871- var result = optlyInstance . getFeatureVariableJson (
6870+ it ( 'returns null from getFeatureVariableJSON if the argument variable key is invalid' , function ( ) {
6871+ var result = optlyInstance . getFeatureVariableJSON (
68726872 'test_feature_for_experiment' ,
68736873 'thisIsNotAVariableKey****' ,
68746874 'user1'
@@ -6966,7 +6966,7 @@ describe('lib/optimizely', function() {
69666966 assert . strictEqual ( logMessage , sprintf ( LOG_MESSAGES . INVALID_OBJECT , 'OPTIMIZELY' , 'getFeatureVariableString' ) ) ;
69676967 } ) ;
69686968
6969- it ( 'returns null from getFeatureVariableJson when optimizely object is not a valid instance' , function ( ) {
6969+ it ( 'returns null from getFeatureVariableJSON when optimizely object is not a valid instance' , function ( ) {
69706970 var instance = new Optimizely ( {
69716971 datafile : { } ,
69726972 errorHandler : errorHandler ,
@@ -6976,11 +6976,11 @@ describe('lib/optimizely', function() {
69766976
69776977 createdLogger . log . reset ( ) ;
69786978
6979- instance . getFeatureVariableJson ( 'test_feature_for_experiment' , 'thisIsNotAVariableKey****' , 'user1' ) ;
6979+ instance . getFeatureVariableJSON ( 'test_feature_for_experiment' , 'thisIsNotAVariableKey****' , 'user1' ) ;
69806980
69816981 sinon . assert . calledOnce ( createdLogger . log ) ;
69826982 var logMessage = createdLogger . log . args [ 0 ] [ 1 ] ;
6983- assert . strictEqual ( logMessage , sprintf ( LOG_MESSAGES . INVALID_OBJECT , 'OPTIMIZELY' , 'getFeatureVariableJson ' ) ) ;
6983+ assert . strictEqual ( logMessage , sprintf ( LOG_MESSAGES . INVALID_OBJECT , 'OPTIMIZELY' , 'getFeatureVariableJSON ' ) ) ;
69846984 } ) ;
69856985 } ) ;
69866986 } ) ;
0 commit comments