@@ -11,7 +11,7 @@ |
||
| 11 | 11 | $credentials = file_get_contents(dirname(__FILE__) . '/../../../auth_credentials.json'); |
| 12 | 12 | if ($credentials===false) { |
| 13 | 13 | $this->fail("Couldn't read OAuth credentials from auth_credentials.json. Make sure " . |
| 14 | - "the file exists (if not, copy from auth_credentials.json.dist)."); |
|
| 14 | + "the file exists (if not, copy from auth_credentials.json.dist)."); |
|
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | $credentials = json_decode($credentials, true); |
@@ -109,16 +109,16 @@ discard block |
||
| 109 | 109 | "platform" => "web", |
| 110 | 110 | "status" => "active", |
| 111 | 111 | "web_snippet" => array( |
| 112 | - "enable_force_variation" => false, |
|
| 113 | - "exclude_disabled_experiments" => false, |
|
| 114 | - "exclude_names" => true, |
|
| 115 | - "include_jquery" => true, |
|
| 116 | - "ip_anonymization" => false, |
|
| 117 | - "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 118 | - "library" => "jquery-1.11.3-trim", |
|
| 119 | - "project_javascript" => "alert(\"Active Experiment\")", |
|
| 120 | - "code_revision" => 0, |
|
| 121 | - "js_file_size" => 63495 |
|
| 112 | + "enable_force_variation" => false, |
|
| 113 | + "exclude_disabled_experiments" => false, |
|
| 114 | + "exclude_names" => true, |
|
| 115 | + "include_jquery" => true, |
|
| 116 | + "ip_anonymization" => false, |
|
| 117 | + "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 118 | + "library" => "jquery-1.11.3-trim", |
|
| 119 | + "project_javascript" => "alert(\"Active Experiment\")", |
|
| 120 | + "code_revision" => 0, |
|
| 121 | + "js_file_size" => 63495 |
|
| 122 | 122 | ), |
| 123 | 123 | "created" => "2016-10-17T07:04:59.991Z", |
| 124 | 124 | "id" => 1000, |
@@ -137,14 +137,14 @@ discard block |
||
| 137 | 137 | "platform" => "web", |
| 138 | 138 | "status" => "active", |
| 139 | 139 | "web_snippet" => array( |
| 140 | - "enable_force_variation" => false, |
|
| 141 | - "exclude_disabled_experiments" => false, |
|
| 142 | - "exclude_names" => true, |
|
| 143 | - "include_jquery" => true, |
|
| 144 | - "ip_anonymization" => false, |
|
| 145 | - "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 146 | - "library" => "jquery-1.11.3-trim", |
|
| 147 | - "project_javascript" => "alert(\"Active Experiment\")" |
|
| 140 | + "enable_force_variation" => false, |
|
| 141 | + "exclude_disabled_experiments" => false, |
|
| 142 | + "exclude_names" => true, |
|
| 143 | + "include_jquery" => true, |
|
| 144 | + "ip_anonymization" => false, |
|
| 145 | + "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 146 | + "library" => "jquery-1.11.3-trim", |
|
| 147 | + "project_javascript" => "alert(\"Active Experiment\")" |
|
| 148 | 148 | ) |
| 149 | 149 | )); |
| 150 | 150 | |
@@ -173,16 +173,16 @@ discard block |
||
| 173 | 173 | "platform" => "web", |
| 174 | 174 | "status" => "active", |
| 175 | 175 | "web_snippet" => array( |
| 176 | - "enable_force_variation" => false, |
|
| 177 | - "exclude_disabled_experiments" => false, |
|
| 178 | - "exclude_names" => true, |
|
| 179 | - "include_jquery" => true, |
|
| 180 | - "ip_anonymization" => false, |
|
| 181 | - "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 182 | - "library" => "jquery-1.11.3-trim", |
|
| 183 | - "project_javascript" => "alert(\"Active Experiment\")", |
|
| 184 | - "code_revision" => 0, |
|
| 185 | - "js_file_size" => 63495 |
|
| 176 | + "enable_force_variation" => false, |
|
| 177 | + "exclude_disabled_experiments" => false, |
|
| 178 | + "exclude_names" => true, |
|
| 179 | + "include_jquery" => true, |
|
| 180 | + "ip_anonymization" => false, |
|
| 181 | + "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 182 | + "library" => "jquery-1.11.3-trim", |
|
| 183 | + "project_javascript" => "alert(\"Active Experiment\")", |
|
| 184 | + "code_revision" => 0, |
|
| 185 | + "js_file_size" => 63495 |
|
| 186 | 186 | ), |
| 187 | 187 | "created" => "2016-10-17T07:04:59.999Z", |
| 188 | 188 | "id" => 1000, |
@@ -199,14 +199,14 @@ discard block |
||
| 199 | 199 | "name" => "Test Project", |
| 200 | 200 | "status" => "active", |
| 201 | 201 | "web_snippet" => array( |
| 202 | - "enable_force_variation" => false, |
|
| 203 | - "exclude_disabled_experiments" => false, |
|
| 204 | - "exclude_names" => true, |
|
| 205 | - "include_jquery" => true, |
|
| 206 | - "ip_anonymization" => false, |
|
| 207 | - "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 208 | - "library" => "jquery-1.11.3-trim", |
|
| 209 | - "project_javascript" => "alert(\"Active Experiment\")" |
|
| 202 | + "enable_force_variation" => false, |
|
| 203 | + "exclude_disabled_experiments" => false, |
|
| 204 | + "exclude_names" => true, |
|
| 205 | + "include_jquery" => true, |
|
| 206 | + "ip_anonymization" => false, |
|
| 207 | + "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 208 | + "library" => "jquery-1.11.3-trim", |
|
| 209 | + "project_javascript" => "alert(\"Active Experiment\")" |
|
| 210 | 210 | ) |
| 211 | 211 | )); |
| 212 | 212 | |
@@ -236,14 +236,14 @@ discard block |
||
| 236 | 236 | "platform" => "web", |
| 237 | 237 | "status" => "active", |
| 238 | 238 | "web_snippet" => array( |
| 239 | - "enable_force_variation" => false, |
|
| 240 | - "exclude_disabled_experiments" => false, |
|
| 241 | - "exclude_names" => true, |
|
| 242 | - "include_jquery" => true, |
|
| 243 | - "ip_anonymization" => false, |
|
| 244 | - "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 245 | - "library" => "jquery-1.11.3-trim", |
|
| 246 | - "project_javascript" => "alert(\"Active Experiment\")" |
|
| 239 | + "enable_force_variation" => false, |
|
| 240 | + "exclude_disabled_experiments" => false, |
|
| 241 | + "exclude_names" => true, |
|
| 242 | + "include_jquery" => true, |
|
| 243 | + "ip_anonymization" => false, |
|
| 244 | + "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 245 | + "library" => "jquery-1.11.3-trim", |
|
| 246 | + "project_javascript" => "alert(\"Active Experiment\")" |
|
| 247 | 247 | ) |
| 248 | 248 | )); |
| 249 | 249 | |
@@ -13,47 +13,47 @@ discard block |
||
| 13 | 13 | "confidence_threshold" => 0, |
| 14 | 14 | "end_time" => "2016-10-14T05:08:42.966Z", |
| 15 | 15 | "metrics" => array( |
| 16 | - array( |
|
| 16 | + array( |
|
| 17 | 17 | "event" => "string", |
| 18 | 18 | "event_name" => "string", |
| 19 | 19 | "measure" => "conversions", |
| 20 | 20 | "metric_id" => "string", |
| 21 | 21 | "priority" => 0, |
| 22 | 22 | "results" => array( |
| 23 | - "campaign" => array( |
|
| 23 | + "campaign" => array( |
|
| 24 | 24 | "experiment_id" => 0, |
| 25 | 25 | "is_baseline" => true, |
| 26 | 26 | "lift" => array( |
| 27 | - "confidence_interval" => array( |
|
| 27 | + "confidence_interval" => array( |
|
| 28 | 28 | 0.010399560300730457, |
| 29 | 29 | 0.0850821459929161 |
| 30 | - ), |
|
| 31 | - "is_most_conclusive" => true, |
|
| 32 | - "is_significant" => true, |
|
| 33 | - "significance" => 0, |
|
| 34 | - "value" => 0, |
|
| 35 | - "visitors_remaining" => 0 |
|
| 30 | + ), |
|
| 31 | + "is_most_conclusive" => true, |
|
| 32 | + "is_significant" => true, |
|
| 33 | + "significance" => 0, |
|
| 34 | + "value" => 0, |
|
| 35 | + "visitors_remaining" => 0 |
|
| 36 | 36 | ), |
| 37 | 37 | "name" => "Blue Button", |
| 38 | 38 | "rate" => 0, |
| 39 | 39 | "scope" => "variation", |
| 40 | 40 | "total_increase" => array( |
| 41 | - "confidence_interval" => array( |
|
| 41 | + "confidence_interval" => array( |
|
| 42 | 42 | 0.010399560300730457, |
| 43 | 43 | 0.0850821459929161 |
| 44 | - ), |
|
| 45 | - "is_most_conclusive" => true, |
|
| 46 | - "is_significant" => true, |
|
| 47 | - "significance" => 0, |
|
| 48 | - "value" => 0, |
|
| 49 | - "visitors_remaining" => 0 |
|
| 44 | + ), |
|
| 45 | + "is_most_conclusive" => true, |
|
| 46 | + "is_significant" => true, |
|
| 47 | + "significance" => 0, |
|
| 48 | + "value" => 0, |
|
| 49 | + "visitors_remaining" => 0 |
|
| 50 | 50 | ), |
| 51 | 51 | "value" => 0, |
| 52 | 52 | "variation_id" => "string" |
| 53 | - ) |
|
| 53 | + ) |
|
| 54 | 54 | ), |
| 55 | 55 | "unit" => "session" |
| 56 | - ) |
|
| 56 | + ) |
|
| 57 | 57 | ), |
| 58 | 58 | "start_time" => "2016-10-14T05:08:42.967Z" |
| 59 | 59 | ); |
@@ -71,47 +71,47 @@ discard block |
||
| 71 | 71 | "confidence_threshold" => 0, |
| 72 | 72 | "end_time" => "2016-10-14T05:08:42.966Z", |
| 73 | 73 | "metrics" => array( |
| 74 | - array( |
|
| 74 | + array( |
|
| 75 | 75 | "event" => "string", |
| 76 | 76 | "event_name" => "string", |
| 77 | 77 | "measure" => "conversions", |
| 78 | 78 | "metric_id" => "string", |
| 79 | 79 | "priority" => 0, |
| 80 | 80 | "results" => array( |
| 81 | - "campaign" => array( |
|
| 81 | + "campaign" => array( |
|
| 82 | 82 | "experiment_id" => 0, |
| 83 | 83 | "is_baseline" => true, |
| 84 | 84 | "lift" => array( |
| 85 | - "confidence_interval" => array( |
|
| 85 | + "confidence_interval" => array( |
|
| 86 | 86 | 0.010399560300730457, |
| 87 | 87 | 0.0850821459929161 |
| 88 | - ), |
|
| 89 | - "is_most_conclusive" => true, |
|
| 90 | - "is_significant" => true, |
|
| 91 | - "significance" => 0, |
|
| 92 | - "value" => 0, |
|
| 93 | - "visitors_remaining" => 0 |
|
| 88 | + ), |
|
| 89 | + "is_most_conclusive" => true, |
|
| 90 | + "is_significant" => true, |
|
| 91 | + "significance" => 0, |
|
| 92 | + "value" => 0, |
|
| 93 | + "visitors_remaining" => 0 |
|
| 94 | 94 | ), |
| 95 | 95 | "name" => "Blue Button", |
| 96 | 96 | "rate" => 0, |
| 97 | 97 | "scope" => "variation", |
| 98 | 98 | "total_increase" => array( |
| 99 | - "confidence_interval" => array( |
|
| 99 | + "confidence_interval" => array( |
|
| 100 | 100 | 0.010399560300730457, |
| 101 | 101 | 0.0850821459929161 |
| 102 | - ), |
|
| 103 | - "is_most_conclusive" => true, |
|
| 104 | - "is_significant" => true, |
|
| 105 | - "significance" => 0, |
|
| 106 | - "value" => 0, |
|
| 107 | - "visitors_remaining" => 0 |
|
| 102 | + ), |
|
| 103 | + "is_most_conclusive" => true, |
|
| 104 | + "is_significant" => true, |
|
| 105 | + "significance" => 0, |
|
| 106 | + "value" => 0, |
|
| 107 | + "visitors_remaining" => 0 |
|
| 108 | 108 | ), |
| 109 | 109 | "value" => 0, |
| 110 | 110 | "variation_id" => "string" |
| 111 | - ) |
|
| 111 | + ) |
|
| 112 | 112 | ), |
| 113 | 113 | "unit" => "session" |
| 114 | - ) |
|
| 114 | + ) |
|
| 115 | 115 | ), |
| 116 | 116 | "start_time" => "2016-10-14T05:08:42.967Z" |
| 117 | 117 | ); |
@@ -14,12 +14,12 @@ discard block |
||
| 14 | 14 | $audience->setConditions(array( |
| 15 | 15 | "and", |
| 16 | 16 | array( |
| 17 | - "value" => "es", |
|
| 18 | - "type" => "language" |
|
| 17 | + "value" => "es", |
|
| 18 | + "type" => "language" |
|
| 19 | 19 | ), |
| 20 | 20 | array( |
| 21 | - "value" => "US-CA-SANFRANCISCO", |
|
| 22 | - "type" => "location" |
|
| 21 | + "value" => "US-CA-SANFRANCISCO", |
|
| 22 | + "type" => "location" |
|
| 23 | 23 | ) |
| 24 | 24 | )); |
| 25 | 25 | $audience->setDescription('People that speak spanish and are in San Francisco'); |
@@ -46,15 +46,15 @@ discard block |
||
| 46 | 46 | "project_id" => 1000, |
| 47 | 47 | "archived" => false, |
| 48 | 48 | "conditions" => array( |
| 49 | - "and", |
|
| 50 | - array( |
|
| 49 | + "and", |
|
| 50 | + array( |
|
| 51 | 51 | "value" => "es", |
| 52 | 52 | "type" => "language" |
| 53 | - ), |
|
| 54 | - array( |
|
| 53 | + ), |
|
| 54 | + array( |
|
| 55 | 55 | "value" => "US-CA-SANFRANCISCO", |
| 56 | 56 | "type" => "location" |
| 57 | - ) |
|
| 57 | + ) |
|
| 58 | 58 | ), |
| 59 | 59 | "description" => "People that speak spanish and are in San Francisco", |
| 60 | 60 | "name" => "Spanish speaking San Franciscans", |
@@ -77,15 +77,15 @@ discard block |
||
| 77 | 77 | "project_id" => 1000, |
| 78 | 78 | "archived" => false, |
| 79 | 79 | "conditions" => array( |
| 80 | - "and", |
|
| 81 | - array( |
|
| 80 | + "and", |
|
| 81 | + array( |
|
| 82 | 82 | "value" => "es", |
| 83 | 83 | "type" => "language" |
| 84 | - ), |
|
| 85 | - array( |
|
| 84 | + ), |
|
| 85 | + array( |
|
| 86 | 86 | "value" => "US-CA-SANFRANCISCO", |
| 87 | 87 | "type" => "location" |
| 88 | - ) |
|
| 88 | + ) |
|
| 89 | 89 | ), |
| 90 | 90 | "description" => "People that speak spanish and are in San Francisco", |
| 91 | 91 | "name" => "Spanish speaking San Franciscans", |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | "end_time" => "2016-10-14T05:08:43.031Z", |
| 14 | 14 | "experiment_id" => 3000, |
| 15 | 15 | "metrics" => array( |
| 16 | - array( |
|
| 16 | + array( |
|
| 17 | 17 | "event" => "string", |
| 18 | 18 | "event_name" => "string", |
| 19 | 19 | "measure" => "conversions", |
@@ -21,54 +21,54 @@ discard block |
||
| 21 | 21 | "priority" => 1, |
| 22 | 22 | "unit" => "session", |
| 23 | 23 | "variation_results" => array( |
| 24 | - "9000" => array( |
|
| 24 | + "9000" => array( |
|
| 25 | 25 | "experiment_id" => 0, |
| 26 | 26 | "is_baseline" => true, |
| 27 | 27 | "lift" => array( |
| 28 | - "confidence_interval" => array( |
|
| 28 | + "confidence_interval" => array( |
|
| 29 | 29 | 0.010399560300730457, |
| 30 | 30 | 0.0850821459929161 |
| 31 | - ), |
|
| 32 | - "is_most_conclusive" => true, |
|
| 33 | - "is_significant" => true, |
|
| 34 | - "significance" => 0, |
|
| 35 | - "value" => 0, |
|
| 36 | - "visitors_remaining" => 0 |
|
| 31 | + ), |
|
| 32 | + "is_most_conclusive" => true, |
|
| 33 | + "is_significant" => true, |
|
| 34 | + "significance" => 0, |
|
| 35 | + "value" => 0, |
|
| 36 | + "visitors_remaining" => 0 |
|
| 37 | 37 | ), |
| 38 | 38 | "name" => "Blue Button", |
| 39 | 39 | "rate" => 0, |
| 40 | 40 | "scope" => "variation", |
| 41 | 41 | "total_increase" => array( |
| 42 | - "confidence_interval" => array( |
|
| 42 | + "confidence_interval" => array( |
|
| 43 | 43 | 0.010399560300730457, |
| 44 | 44 | 0.0850821459929161 |
| 45 | - ), |
|
| 46 | - "is_most_conclusive" => true, |
|
| 47 | - "is_significant" => true, |
|
| 48 | - "significance" => 0, |
|
| 49 | - "value" => 0, |
|
| 50 | - "visitors_remaining" => 0 |
|
| 45 | + ), |
|
| 46 | + "is_most_conclusive" => true, |
|
| 47 | + "is_significant" => true, |
|
| 48 | + "significance" => 0, |
|
| 49 | + "value" => 0, |
|
| 50 | + "visitors_remaining" => 0 |
|
| 51 | 51 | ), |
| 52 | 52 | "value" => 0, |
| 53 | 53 | "variation_id" => "string" |
| 54 | - ) |
|
| 54 | + ) |
|
| 55 | + ) |
|
| 55 | 56 | ) |
| 56 | - ) |
|
| 57 | 57 | ), |
| 58 | 58 | "reach" => array( |
| 59 | - "baseline_count" => 0, |
|
| 60 | - "baseline_reach" => 0, |
|
| 61 | - "total_count" => 0, |
|
| 62 | - "treatment_count" => 0, |
|
| 63 | - "treatment_reach" => 0, |
|
| 64 | - "variations" => array( |
|
| 59 | + "baseline_count" => 0, |
|
| 60 | + "baseline_reach" => 0, |
|
| 61 | + "total_count" => 0, |
|
| 62 | + "treatment_count" => 0, |
|
| 63 | + "treatment_reach" => 0, |
|
| 64 | + "variations" => array( |
|
| 65 | 65 | "9000" => array( |
| 66 | - "count" => 0, |
|
| 67 | - "name" => "Blue Button", |
|
| 68 | - "variation_id" => "string", |
|
| 69 | - "variation_reach" => 0 |
|
| 66 | + "count" => 0, |
|
| 67 | + "name" => "Blue Button", |
|
| 68 | + "variation_id" => "string", |
|
| 69 | + "variation_reach" => 0 |
|
| 70 | + ) |
|
| 70 | 71 | ) |
| 71 | - ) |
|
| 72 | 72 | ), |
| 73 | 73 | "start_time" => "2016-10-14T05:08:43.032Z" |
| 74 | 74 | ); |
@@ -86,7 +86,7 @@ discard block |
||
| 86 | 86 | "end_time" => "2016-10-14T05:08:43.031Z", |
| 87 | 87 | "experiment_id" => 3000, |
| 88 | 88 | "metrics" => array( |
| 89 | - array( |
|
| 89 | + array( |
|
| 90 | 90 | "event" => "string", |
| 91 | 91 | "event_name" => "string", |
| 92 | 92 | "measure" => "conversions", |
@@ -94,54 +94,54 @@ discard block |
||
| 94 | 94 | "priority" => 1, |
| 95 | 95 | "unit" => "session", |
| 96 | 96 | "variation_results" => array( |
| 97 | - "9000" => array( |
|
| 97 | + "9000" => array( |
|
| 98 | 98 | "experiment_id" => 0, |
| 99 | 99 | "is_baseline" => true, |
| 100 | 100 | "lift" => array( |
| 101 | - "confidence_interval" => array( |
|
| 101 | + "confidence_interval" => array( |
|
| 102 | 102 | 0.010399560300730457, |
| 103 | 103 | 0.0850821459929161 |
| 104 | - ), |
|
| 105 | - "is_most_conclusive" => true, |
|
| 106 | - "is_significant" => true, |
|
| 107 | - "significance" => 0, |
|
| 108 | - "value" => 0, |
|
| 109 | - "visitors_remaining" => 0 |
|
| 104 | + ), |
|
| 105 | + "is_most_conclusive" => true, |
|
| 106 | + "is_significant" => true, |
|
| 107 | + "significance" => 0, |
|
| 108 | + "value" => 0, |
|
| 109 | + "visitors_remaining" => 0 |
|
| 110 | 110 | ), |
| 111 | 111 | "name" => "Blue Button", |
| 112 | 112 | "rate" => 0, |
| 113 | 113 | "scope" => "variation", |
| 114 | 114 | "total_increase" => array( |
| 115 | - "confidence_interval" => array( |
|
| 115 | + "confidence_interval" => array( |
|
| 116 | 116 | 0.010399560300730457, |
| 117 | 117 | 0.0850821459929161 |
| 118 | - ), |
|
| 119 | - "is_most_conclusive" => true, |
|
| 120 | - "is_significant" => true, |
|
| 121 | - "significance" => 0, |
|
| 122 | - "value" => 0, |
|
| 123 | - "visitors_remaining" => 0 |
|
| 118 | + ), |
|
| 119 | + "is_most_conclusive" => true, |
|
| 120 | + "is_significant" => true, |
|
| 121 | + "significance" => 0, |
|
| 122 | + "value" => 0, |
|
| 123 | + "visitors_remaining" => 0 |
|
| 124 | 124 | ), |
| 125 | 125 | "value" => 0, |
| 126 | 126 | "variation_id" => "string" |
| 127 | - ) |
|
| 127 | + ) |
|
| 128 | + ) |
|
| 128 | 129 | ) |
| 129 | - ) |
|
| 130 | 130 | ), |
| 131 | 131 | "reach" => array( |
| 132 | - "baseline_count" => 0, |
|
| 133 | - "baseline_reach" => 0, |
|
| 134 | - "total_count" => 0, |
|
| 135 | - "treatment_count" => 0, |
|
| 136 | - "treatment_reach" => 0, |
|
| 137 | - "variations" => array( |
|
| 132 | + "baseline_count" => 0, |
|
| 133 | + "baseline_reach" => 0, |
|
| 134 | + "total_count" => 0, |
|
| 135 | + "treatment_count" => 0, |
|
| 136 | + "treatment_reach" => 0, |
|
| 137 | + "variations" => array( |
|
| 138 | 138 | "9000" => array( |
| 139 | - "count" => 0, |
|
| 140 | - "name" => "Blue Button", |
|
| 141 | - "variation_id" => "string", |
|
| 142 | - "variation_reach" => 0 |
|
| 139 | + "count" => 0, |
|
| 140 | + "name" => "Blue Button", |
|
| 141 | + "variation_id" => "string", |
|
| 142 | + "variation_reach" => 0 |
|
| 143 | + ) |
|
| 143 | 144 | ) |
| 144 | - ) |
|
| 145 | 145 | ), |
| 146 | 146 | "start_time" => "2016-10-14T05:08:43.032Z" |
| 147 | 147 | ); |
@@ -43,8 +43,8 @@ discard block |
||
| 43 | 43 | "category" => "add_to_cart", |
| 44 | 44 | "description" => "Item added to cart", |
| 45 | 45 | "event_filter" => array( |
| 46 | - "filter_type" => "target_selector", |
|
| 47 | - "selector" => ".menu-options" |
|
| 46 | + "filter_type" => "target_selector", |
|
| 47 | + "selector" => ".menu-options" |
|
| 48 | 48 | ), |
| 49 | 49 | "event_type" => "custom", |
| 50 | 50 | "key" => "add_to_cart", |
@@ -73,8 +73,8 @@ discard block |
||
| 73 | 73 | "category" => "add_to_cart", |
| 74 | 74 | "description" => "Item added to cart", |
| 75 | 75 | "event_filter" => array( |
| 76 | - "filter_type" => "target_selector", |
|
| 77 | - "selector" => ".menu-options" |
|
| 76 | + "filter_type" => "target_selector", |
|
| 77 | + "selector" => ".menu-options" |
|
| 78 | 78 | ), |
| 79 | 79 | "event_type" => "custom", |
| 80 | 80 | "key" => "add_to_cart", |
@@ -16,14 +16,14 @@ |
||
| 16 | 16 | "platform" => "web", |
| 17 | 17 | "status" => "active", |
| 18 | 18 | "web_snippet" => array( |
| 19 | - "enable_force_variation" => false, |
|
| 20 | - "exclude_disabled_experiments" => false, |
|
| 21 | - "exclude_names" => true, |
|
| 22 | - "include_jquery" => true, |
|
| 23 | - "ip_anonymization" => false, |
|
| 24 | - "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 25 | - "library" => "jquery-1.11.3-trim", |
|
| 26 | - "project_javascript" => "alert(\"Active Experiment\")" |
|
| 19 | + "enable_force_variation" => false, |
|
| 20 | + "exclude_disabled_experiments" => false, |
|
| 21 | + "exclude_names" => true, |
|
| 22 | + "include_jquery" => true, |
|
| 23 | + "ip_anonymization" => false, |
|
| 24 | + "ip_filter" => "^206\\.23\\.100\\.([5-9][0-9]|1([0-4][0-9]|50))$", |
|
| 25 | + "library" => "jquery-1.11.3-trim", |
|
| 26 | + "project_javascript" => "alert(\"Active Experiment\")" |
|
| 27 | 27 | )); |
| 28 | 28 | |
| 29 | 29 | $result = new Result($data, 200); |
@@ -33,73 +33,73 @@ |
||
| 33 | 33 | $experiment = new Experiment(array( |
| 34 | 34 | "project_id" => 1000, |
| 35 | 35 | "audience_ids" => array( |
| 36 | - 1234, |
|
| 37 | - 1212, |
|
| 38 | - 1432 |
|
| 36 | + 1234, |
|
| 37 | + 1212, |
|
| 38 | + 1432 |
|
| 39 | 39 | ), |
| 40 | 40 | "campaign_id" => 2000, |
| 41 | 41 | "changes" => array( |
| 42 | - array( |
|
| 42 | + array( |
|
| 43 | 43 | "type" => "custom_code", |
| 44 | 44 | "allow_additional_redirect" => true, |
| 45 | 45 | "async" => true, |
| 46 | 46 | "css_selector" => "a[href*=\"optimizely\"]", |
| 47 | 47 | "dependencies" => array( |
| 48 | - 24, |
|
| 49 | - 26 |
|
| 48 | + 24, |
|
| 49 | + 26 |
|
| 50 | 50 | ), |
| 51 | 51 | "destination" => "https://app.optimizely.com/", |
| 52 | 52 | "extension_id" => 1234, |
| 53 | 53 | "preserve_parameters" => true, |
| 54 | 54 | "src" => 524, |
| 55 | 55 | "value" => "window.someGlobalFunction();" |
| 56 | - ) |
|
| 56 | + ) |
|
| 57 | 57 | ), |
| 58 | 58 | "description" => "string", |
| 59 | 59 | "holdback" => 5000, |
| 60 | 60 | "key" => "home_page_experiment", |
| 61 | 61 | "metrics" => array( |
| 62 | - array( |
|
| 62 | + array( |
|
| 63 | 63 | "kind" => "string" |
| 64 | - ) |
|
| 64 | + ) |
|
| 65 | 65 | ), |
| 66 | 66 | "name" => "Blue Button Experiment", |
| 67 | 67 | "schedule" => array( |
| 68 | - "start_time" => "2016-10-17T07:04:59.724Z", |
|
| 69 | - "stop_time" => "2016-10-17T07:04:59.724Z", |
|
| 70 | - "time_zone" => "UTC" |
|
| 68 | + "start_time" => "2016-10-17T07:04:59.724Z", |
|
| 69 | + "stop_time" => "2016-10-17T07:04:59.724Z", |
|
| 70 | + "time_zone" => "UTC" |
|
| 71 | 71 | ), |
| 72 | 72 | "status" => "active", |
| 73 | 73 | "variations" => array( |
| 74 | - array( |
|
| 74 | + array( |
|
| 75 | 75 | "actions" => array( |
| 76 | - array( |
|
| 76 | + array( |
|
| 77 | 77 | "changes" => array( |
| 78 | - array( |
|
| 78 | + array( |
|
| 79 | 79 | "type" => "custom_code", |
| 80 | 80 | "allow_additional_redirect" => true, |
| 81 | 81 | "async" => true, |
| 82 | 82 | "css_selector" => "a[href*=\"optimizely\"]", |
| 83 | 83 | "dependencies" => array( |
| 84 | - 24, |
|
| 85 | - 26 |
|
| 84 | + 24, |
|
| 85 | + 26 |
|
| 86 | 86 | ), |
| 87 | 87 | "destination" => "https://app.optimizely.com/", |
| 88 | 88 | "extension_id" => 1234, |
| 89 | 89 | "preserve_parameters" => true, |
| 90 | 90 | "src" => 524, |
| 91 | 91 | "value" => "window.someGlobalFunction();" |
| 92 | - ) |
|
| 92 | + ) |
|
| 93 | 93 | ), |
| 94 | 94 | "page_id" => 0 |
| 95 | - ) |
|
| 95 | + ) |
|
| 96 | 96 | ), |
| 97 | 97 | "archived" => true, |
| 98 | 98 | "key" => "blue_button_variation", |
| 99 | 99 | "name" => "Blue Button", |
| 100 | 100 | "variation_id" => 0, |
| 101 | 101 | "weight" => 0 |
| 102 | - ) |
|
| 102 | + ) |
|
| 103 | 103 | ) |
| 104 | 104 | )); |
| 105 | 105 | |
@@ -16,7 +16,7 @@ |
||
| 16 | 16 | $credentials = file_get_contents(dirname(__FILE__) . '/auth_credentials.json'); |
| 17 | 17 | if ($credentials===false) { |
| 18 | 18 | throw new \Exception("Couldn't read OAuth credentials from auth_credentials.json. Make sure " . |
| 19 | - "the file exists (if not, copy from auth_credentials.json.dist)."); |
|
| 19 | + "the file exists (if not, copy from auth_credentials.json.dist)."); |
|
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | $credentials = json_decode($credentials, true); |