public void DeletingNullListFails() { var item = new ConfigEnvironment(new EnvironmentIdentifier("Foo", "Bar")); var result = item.DeleteKeys(null); Assert.True(result.IsError, "result.IsError"); }
public void DeletingInvalidKeysFails() { var item = new ConfigEnvironment(new EnvironmentIdentifier("Foo", "Bar")); item.UpdateKeys(new List <ConfigEnvironmentKey> { new ConfigEnvironmentKey("Foo", "Bar", "", "", 0) }); Assert.NotEmpty(item.Keys); var result = item.DeleteKeys(new List <string> { "Baz" }); Assert.True(result.IsError, "result.IsError"); }
public void DeleteKeysChangesValues() { var item = new ConfigEnvironment(new EnvironmentIdentifier("Foo", "Bar")); item.UpdateKeys(new List <ConfigEnvironmentKey> { new ConfigEnvironmentKey("Foo", "Bar", "", "", 0) }); Assert.NotEmpty(item.Keys); item.DeleteKeys(new List <string> { "Foo" }); Assert.Empty(item.Keys); }