private static WarehouseItemAssertionTestData CreateWarehouseItemAssertionTestData(ListViewRow t) { return new WarehouseItemAssertionTestData { Kind = t.Cells["Kind"].Text, Price = double.Parse(t.Cells["Price"].Text), Quantity = int.Parse(t.Cells["Quantity"].Text), TotalCost = double.Parse(t.Cells["Total cost"].Text) }; }
public virtual void Select(string text) { ListViewRows rows = Rows; ListViewRow row = rows.Find(obj => obj.Cells[0].Text.Equals(text)); if (row == null) { throw new UIActionException("Could not find suggestion " + text); } row.Select(); SuggestionListView.WaitTillNotPresent(); actionListener.ActionPerformed(Action.WindowMessage); }
private Dictionary<string, string> RowToDictionary(ListViewRow row, List<string> names) { var values = row.Cells.Select(c => c.Text).ToList(); var combined = names.Zip(values, (k, v) => new { k, v }); return combined.ToDictionary(x => x.k, x => x.v); }