public void TestCustomDelegateFeatures() { var customDelegateGreen = new MyCustomEnumConditionalRedFeature(() => MyColorEnum.Green); Assert.True(customDelegateGreen.Is(MyColorEnum.Green), $"{customDelegateGreen.GetType().Name} delegate failed"); var customDelegateRed = new MyCustomEnumConditionalGreenFeature(() => MyColorEnum.Red); Assert.True(customDelegateRed.Is(MyColorEnum.Red), $"{customDelegateRed.GetType().Name} delegate failed"); }
public void TestCustomOverrideFeatures() { var customGreen = new MyCustomEnumConditionalGreenFeature(); Assert.True(customGreen.Is(MyColorEnum.Green), $"{customGreen.GetType().Name} failed"); var customRed = new MyCustomEnumConditionalRedFeature(); Assert.True(customRed.Is(MyColorEnum.Red), $"{customRed.GetType().Name} failed"); }