File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -1063,6 +1063,12 @@ def setUp(self):
1063
1063
raw_split ['trafficAllocationSeed' ] = - 1
1064
1064
self ._splitObjects ['rollout2' ] = split_parser .parse (raw_split , True )
1065
1065
1066
+ raw_split ['name' ] = 'test4'
1067
+ raw_split ['trafficAllocation' ] = None #must be mapped as 100
1068
+ raw_split ['trafficAllocationSeed' ] = - 1
1069
+ self ._splitObjects ['rollout3' ] = split_parser .parse (raw_split , True )
1070
+
1071
+
1066
1072
def testTrafficAllocation (self ):
1067
1073
'''
1068
1074
'''
@@ -1080,3 +1086,8 @@ def testTrafficAllocation(self):
1080
1086
self ._splitObjects ['rollout2' ], 'testKey' , None
1081
1087
)
1082
1088
self .assertEqual (treatment3 , 'default' )
1089
+
1090
+ treatment4 , label1 = self ._client ._get_treatment_for_split (
1091
+ self ._splitObjects ['rollout3' ], 'testKey' , None
1092
+ )
1093
+ self .assertEqual (treatment4 , 'on' )
You can’t perform that action at this time.
0 commit comments