@@ -187,7 +187,8 @@ async def test_get_variant_value_returns_variant_when_rollout_percentage_hundred
187187 result = self ._flags .get_variant_value (TEST_FLAG_KEY , "fallback" , USER_CONTEXT )
188188 assert result != "fallback"
189189
190-
190+ # TODO Joshua start here
191+ # TODO problem test doesn't fail
191192 @respx .mock
192193 async def test_get_variant_value_respects_runtime_evaluation_rule_satisfied (self ):
193194 runtime_eval = {
@@ -219,35 +220,7 @@ def user_context_with_properties(self, properties: Dict[str, Any]) -> Dict[str,
219220 return context
220221
221222 @respx .mock
222- async def test_get_variant_value_ignores_legacy_runtime_evaluation_definition_when_runtime_evaluation_rule_is_present__satisfied (self ):
223- runtime_rule = {
224- "==" : [{"var" : "plan" }, "premium" ]
225- }
226- legacy_runtime_definition = {"plan" : "basic" }
227- flag = create_test_flag (runtime_evaluation_rule = runtime_rule , runtime_evaluation_legacy_definition = legacy_runtime_definition )
228- await self .setup_flags ([flag ])
229- context = self .user_context_with_properties ({
230- "plan" : "premium" ,
231- })
232- result = self ._flags .get_variant_value (TEST_FLAG_KEY , "fallback" , context )
233- assert result != "fallback"
234-
235- @respx .mock
236- async def test_get_variant_value_ignores_legacy_runtime_evaluation_definition_when_runtime_evaluation_rule_is_present__not_satisfied (self ):
237- runtime_rule = {
238- "==" : [{"var" : "plan" }, "basic" ]
239- }
240- legacy_runtime_definition = {"plan" : "premium" }
241- flag = create_test_flag (runtime_evaluation_rule = runtime_rule , runtime_evaluation_legacy_definition = legacy_runtime_definition )
242- await self .setup_flags ([flag ])
243- context = self .user_context_with_properties ({
244- "plan" : "premium" ,
245- })
246- result = self ._flags .get_variant_value (TEST_FLAG_KEY , "fallback" , context )
247- assert result == "fallback"
248-
249- @respx .mock
250- async def test_get_variant_value_respects_legacy_runtime_evaluation_satisfied (self ):
223+ async def test_get_variant_value_respects_runtime_evaluation_satisfied (self ):
251224 runtime_eval = {"plan" : "premium" , "region" : "US" }
252225 flag = create_test_flag (runtime_evaluation_legacy_definition = runtime_eval )
253226 await self .setup_flags ([flag ])
@@ -259,7 +232,7 @@ async def test_get_variant_value_respects_legacy_runtime_evaluation_satisfied(se
259232 assert result != "fallback"
260233
261234 @respx .mock
262- async def test_get_variant_value_returns_fallback_when_legacy_runtime_evaluation_not_satisfied (self ):
235+ async def test_get_variant_value_returns_fallback_when_runtime_evaluation_not_satisfied (self ):
263236 runtime_eval = {"plan" : "premium" , "region" : "US" }
264237 flag = create_test_flag (runtime_evaluation_legacy_definition = runtime_eval )
265238 await self .setup_flags ([flag ])
0 commit comments