public void InvalidTypeCast() { CreateConditions(Operator.EQ); var attributes = new[] { UnlaunchAttribute.NewBoolean(AttributeKey, true) }; Assert.Throws <InvalidCastException>(() => OffVariationTargetingRulesNotMatch(attributes)); }
public void InvalidType() { CreateConditions(Operator.SW); var attributes = new[] { UnlaunchAttribute.NewBoolean(AttributeKey, true) }; OffVariationTargetingRulesNotMatch(attributes); }
public void Boolean() { CreateNotEqualsCondition(AttributeType.Boolean, "false"); var attributes = new[] { UnlaunchAttribute.NewBoolean(AttributeKey, true) }; OnVariationTargetingRulesMatch(attributes); }
public void InvalidAttributeKey() { var flag = FlagResponse.data.flags.First(); flag.rules.First().conditions = new[] { new TargetRuleConditionDto { id = 119, attribute = AttributeKey, type = AttributeType.Boolean, op = Operator.EQ, value = "True" } }; LoadFeatureFlags(); var attributes = new[] { UnlaunchAttribute.NewBoolean("wrongKey", true) }; OffVariationTargetingRulesNotMatch(attributes); }