public void ValidatePropertiesTest()
        {
            PropertiesManager target = new PropertiesManager();
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();
            PropertiesManager.AddComponentProperties(customPropertyCollection);

            Assert.AreEqual<DTSValidationStatus>(DTSValidationStatus.VS_ISVALID, target.ValidateProperties(customPropertyCollection, DTSValidationStatus.VS_ISVALID));
        }
        public void ValidatePropertiesTest()
        {
            PropertiesManager target = new PropertiesManager();
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();

            PropertiesManager.AddComponentProperties(customPropertyCollection);

            Assert.AreEqual <DTSValidationStatus>(DTSValidationStatus.VS_ISVALID, target.ValidateProperties(customPropertyCollection, DTSValidationStatus.VS_ISVALID));
        }
        public void AddCustomPropertyTest1()
        {
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();

            PropertiesManager_Accessor.AddCustomProperty(customPropertyCollection, "Name", "Description", "Value");

            Assert.AreEqual <string>("Value", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, "Name"));
            Assert.AreEqual(null, PropertiesManager.GetPropertyValue(customPropertyCollection, "Unexpected"));
        }
        public void GetPropertyValueTest()
        {
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();
            IDTSCustomProperty100           property = customPropertyCollection.New();

            property.Name  = "Name";
            property.Value = 77;
            Assert.AreEqual <int>(77, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, "Name"));
        }
        public void AddCustomPropertyTest()
        {
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();

            PropertiesManager_Accessor.AddCustomProperty(customPropertyCollection, "NewName", "Test description", 100.25, "TestConverter");
            IDTSCustomProperty100 prop = customPropertyCollection["NewName"];

            Assert.AreEqual <string>("Test description", prop.Description);
            Assert.AreEqual <string>("TestConverter", prop.TypeConverter);
            Assert.AreEqual(100.25, prop.Value);
        }
        public void AddComponentPropertiesTest()
        {
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();

            PropertiesManager.AddComponentProperties(customPropertyCollection);

            Assert.AreEqual <string>(",", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.ColumnDelimiterPropName));
            Assert.AreEqual <string>("\r\n", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.RowDelimiterPropName));
            Assert.AreEqual <string>(string.Empty, (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.TextQualifierPropName));
            Assert.AreEqual <string>("\r\n", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.HeaderRowDelimiterPropName));
            Assert.AreEqual <bool>(true, (bool)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.IsUnicodePropName));
            Assert.AreEqual <bool>(true, (bool)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.TreatEmptyStringsAsNullPropName));
            Assert.AreEqual <bool>(false, (bool)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.ColumnNamesInFirstRowPropName));
            Assert.AreEqual <int>(1252, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.CodePagePropName));
            Assert.AreEqual <int>(0, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.DataRowsToSkipPropName));
            Assert.AreEqual <int>(0, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.HeaderRowsToSkipPropName));
        }
        public void AddComponentPropertiesTest()
        {
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();
            PropertiesManager.AddComponentProperties(customPropertyCollection);

            Assert.AreEqual<string>(",", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.ColumnDelimiterPropName));
            Assert.AreEqual<string>("\r\n", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.RowDelimiterPropName));
            Assert.AreEqual<string>(string.Empty, (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.TextQualifierPropName));
            Assert.AreEqual<string>("\r\n", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.HeaderRowDelimiterPropName));
            Assert.AreEqual<bool>(true, (bool)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.IsUnicodePropName));
            Assert.AreEqual<bool>(true, (bool)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.TreatEmptyStringsAsNullPropName));
            Assert.AreEqual<bool>(false, (bool)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.ColumnNamesInFirstRowPropName));
            Assert.AreEqual<int>(1252, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.CodePagePropName));
            Assert.AreEqual<int>(0, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.DataRowsToSkipPropName));
            Assert.AreEqual<int>(0, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, PropertiesManager.HeaderRowsToSkipPropName));
        }
        public void AddCustomPropertyTest()
        {
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();
            PropertiesManager_Accessor.AddCustomProperty(customPropertyCollection, "NewName", "Test description", 100.25, "TestConverter");
            IDTSCustomProperty100 prop = customPropertyCollection["NewName"];

            Assert.AreEqual<string>("Test description", prop.Description);
            Assert.AreEqual<string>("TestConverter", prop.TypeConverter);
            Assert.AreEqual(100.25, prop.Value);
        }
        public void AddCustomPropertyTest1()
        {
            IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();
            PropertiesManager_Accessor.AddCustomProperty(customPropertyCollection, "Name", "Description", "Value");

            Assert.AreEqual<string>("Value", (string)PropertiesManager.GetPropertyValue(customPropertyCollection, "Name"));
            Assert.AreEqual(null, PropertiesManager.GetPropertyValue(customPropertyCollection, "Unexpected"));
        }
 public void GetPropertyValueTest()
 {
     IDTSCustomPropertyCollection100 customPropertyCollection = new CustomPropertyCollectionTestImpl();
     IDTSCustomProperty100 property = customPropertyCollection.New();
     property.Name = "Name";
     property.Value = 77;
     Assert.AreEqual<int>(77, (int)PropertiesManager.GetPropertyValue(customPropertyCollection, "Name"));
 }