public static void Default(object defaultValue) { TestBaseAttribute baseAttribute = new TestBaseAttribute(); baseAttribute.Default = defaultValue; Assert.Equal(defaultValue, baseAttribute.Default); }
public static void HelpText(string helpText, Type resourceType, string expected) { TestBaseAttribute baseAttribute = new TestBaseAttribute(); baseAttribute.HelpText = helpText; baseAttribute.ResourceType = resourceType; Assert.Equal(expected, baseAttribute.HelpText); }
public void ThrowsHelpText(string helpText, Type resourceType) { TestBaseAttribute baseAttribute = new TestBaseAttribute(); baseAttribute.HelpText = helpText; baseAttribute.ResourceType = resourceType; // Verify exception Assert.Throws <ArgumentException>(() => baseAttribute.HelpText.ToString()); }
protected bool Equals(TestBaseAttribute other) { if (other is null) { return(false); } if (ReferenceEquals(this, other)) { return(true); } return(_id == other._id); }
public static void Default(object defaultValue) { TestBaseAttribute baseAttribute = new TestBaseAttribute(); baseAttribute.Default = defaultValue; Assert.Equal(defaultValue, baseAttribute.Default); }