/// <summary> /// Initializes the properties dictionary. /// </summary> /// <returns>The dictionary.</returns> private static Dictionary <string, UITestPropertyDescriptor> InitializePropertiesMap() { Dictionary <string, UITestPropertyDescriptor> map = new Dictionary <string, UITestPropertyDescriptor>(StringComparer.OrdinalIgnoreCase); const UITestPropertyAttributes Read = UITestPropertyAttributes.Readable | UITestPropertyAttributes.DoNotGenerateProperties; // UITestPropertyAttributes readWrite = read | UITestPropertyAttributes.Writable; const UITestPropertyAttributes ReadSearch = Read | UITestPropertyAttributes.Searchable; const UITestPropertyAttributes ReadNonAssertable = Read | UITestPropertyAttributes.NonAssertable; map.Add(PropertyNames.DocumentName, new UITestPropertyDescriptor(typeof(string), Read)); map.Add(PropertyNames.StartIndex, new UITestPropertyDescriptor(typeof(int), ReadSearch)); map.Add(PropertyNames.EndIndex, new UITestPropertyDescriptor(typeof(int), ReadSearch)); // map.Add(PropertyNames.Text, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.Text, new UITestPropertyDescriptor(typeof(string), Read)); map.Add(PropertyNames.TextLength, new UITestPropertyDescriptor(typeof(int), Read)); map.Add(PropertyNames.BoundingRectangle, new UITestPropertyDescriptor(typeof(bool), ReadNonAssertable)); return(map); }
private static Dictionary <string, UITestPropertyDescriptor> InitializePropertiesMap() { var map = new Dictionary <string, UITestPropertyDescriptor>(StringComparer.OrdinalIgnoreCase); UITestPropertyAttributes read = UITestPropertyAttributes.Readable | UITestPropertyAttributes.DoNotGenerateProperties; UITestPropertyAttributes readWrite = read | UITestPropertyAttributes.Writable; UITestPropertyAttributes readSearch = read | UITestPropertyAttributes.Searchable; map.Add(PropertyNames.CellValue, new UITestPropertyDescriptor(typeof(object), readWrite)); map.Add(PropertyNames.ColumnHeader, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.Text, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.Description, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.SelectedRanges, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.Format, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.FormulaTag, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.CellWidth, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.CellHeight, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.FormattedText, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.RowCount, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.ColumnCount, new UITestPropertyDescriptor(typeof(string), readWrite)); map.Add(PropertyNames.GridName, new UITestPropertyDescriptor(typeof(string), readWrite)); return(map); }