Skip to content

Commit cd6cc62

Browse files
[FSSDK-12337] Fix experiment type values to match backend
Update EXPERIMENT_TYPES to use actual backend values: 'multi_armed_bandit' and 'contextual_multi_armed_bandit' instead of shorthand 'mab' and 'cmab'. Restore accidentally removed else branch in spec_params deep_clone.
1 parent 50298ca commit cd6cc62

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

lib/optimizely/helpers/constants.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ module Helpers
2020
module Constants
2121
EXPERIMENT_TYPES = {
2222
'ab' => 'a/b',
23-
'mab' => 'mab',
24-
'cmab' => 'cmab',
23+
'mab' => 'multi_armed_bandit',
24+
'cmab' => 'contextual_multi_armed_bandit',
2525
'td' => 'targeted_delivery',
2626
'fr' => 'feature_rollout'
2727
}.freeze

spec/spec_params.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2062,6 +2062,8 @@ def self.deep_clone(obj)
20622062
new_obj.map! do |val|
20632063
deep_clone(val)
20642064
end
2065+
else
2066+
new_obj
20652067
end
20662068
end
20672069
end

0 commit comments

Comments
 (0)