Example #1
0
        public void GetDefault()
        {
            UserSettings.Clear();

            var cut = UserSettings.Get <SimpleUserSetting>();

            // do nothing

            Assert.AreEqual(cut.Name, SimpleUserSetting.DefaultName);
        }
Example #2
0
        public void TestClear()
        {
            var cut = UserSettings.Get <SimpleUserSetting>();

            cut.Name = "Some Name";
            cut.Save();
            UserSettings.Clear();

            var read = UserSettings.Get <SimpleUserSetting>();

            Assert.AreNotEqual(cut.Name, read.Name);
        }
 //[MenuItem("Properties/UI/Clear PersistentState")]
 public static void ClearState()
 {
     UserSettings <UiPersistentState> .Clear(Key);
 }