public FindByteArray ( string settingName, byte defaultValue ) : byte[] | ||
settingName | string | The name of the setting. |
defaultValue | byte | The default value of the setting if it is not found. |
Результат | byte[] |
public void FindByteArray_WithInvalidSetting_ReturnsDefault() { var helper = new RuleSettingsHelper(); var expected = new byte[] { 1, 2, 3 }; CollectionAssert.AreEqual(expected, helper.FindByteArray("good", expected)); }
public void FindByteArray_WithValidSetting_ReturnsValue() { var helper = new RuleSettingsHelper(); var expected = new byte[] { 1, 2, 3 }; var defaultValue = new byte[] { 4, 5, 6 }; helper.Add("good", expected); CollectionAssert.AreEqual(expected, helper.FindByteArray("good", defaultValue)); }
public void FindByteArray_WithValidSetting_ReturnsValue() { var helper = new RuleSettingsHelper(); var expected = new byte[] { 1, 2, 3 }; var defaultValue = new byte[] { 4, 5, 6 }; helper.Add("good", expected); CollectionAssert.AreEqual(expected, helper.FindByteArray("good", defaultValue)); }
public void FindByteArray_WithInvalidSetting_ReturnsDefault() { var helper = new RuleSettingsHelper(); var expected = new byte[] { 1, 2, 3 }; CollectionAssert.AreEqual(expected, helper.FindByteArray("good", expected)); }