public void RemoveAllKeysDontTouchOthers() { ApplicationData.Current.RoamingSettings.Values["bogus"] = "yo dude"; var k = new IndicoApiKey() { ApiKey = "key", SecretKey = "noway", Site = "indico.cern.ch" }; IndicoApiKeyAccess.UpdateKey(k); IndicoApiKeyAccess.RemoveAllKeys(); Assert.IsTrue(ApplicationData.Current.RoamingSettings.Values.ContainsKey("bogus")); ApplicationData.Current.RoamingSettings.Values.Remove("bogus"); }
public void RemoveAllKeys() { int count = 0; IndicoApiKeyAccess.IndicoApiKeysUpdated.Subscribe(x => count++); var k = new IndicoApiKey() { ApiKey = "key", SecretKey = "noway", Site = "indico.cern.ch" }; IndicoApiKeyAccess.UpdateKey(k); IndicoApiKeyAccess.RemoveAllKeys(); var fk = IndicoApiKeyAccess.GetKey("indico.cern.ch"); Assert.IsNull(fk); Assert.AreEqual(2, count); }
public void ResetApiKeyStore() { IndicoApiKeyAccess.RemoveAllKeys(); }