Example #1
0
        public void SettingsWriteRead()
        {
            var settings = new NonRoamingUserSettings();
            settings.SalomePath = "adsfasd fasdf asdf asdf";
            settings.Destroy();
            settings.Save();

            var settings2 = new NonRoamingUserSettings();
            Assert.IsNull(settings2.SalomePath);
            settings2.Read();
            Assert.AreEqual(settings.SalomePath, settings2.SalomePath);
        }
        public DbCommandShortcut()
        {
            var settings = new NonRoamingUserSettings().Read();
                            var connectionString = String.Format("server={0};uid={1};pwd={2};database={3};",
                    settings.DatabaseAddress,
                    settings.DatabaseUser,
                    settings.DatabasePassword,
                    settings.DatabaseName);

            _cnn = new MySqlConnection(connectionString);
            _cmd = new MySqlCommand();

            _cnn.Open();
            _cmd.Connection = _cnn;
        }
Example #3
0
 public void SettingsReadNonExisting()
 {
     var settings = new NonRoamingUserSettings();
     settings.Destroy();
     settings.Read();
 }