сегодня проверяемс и работаем с методами)

Aug 15, 2011 12:27

 $sel->select($select_locator, $option_locator) Select an option from a drop-down using an option locator. Option locators provide different ways of specifying options of an HTMLSelect element (e.g. for selecting a specific option, or for assertingthat the selected option satisfies a specification). There are severalforms of Select Option Locator.
label=labelPattern:matches options based on their labels, i.e. the visible text. (Thisis the default.)
label=regexp:^[Oo]ther
value=valuePattern:matches options based on their values.
value=other
id=id:matches options based on their ids.
id=option1
index=index:matches an option based on its index (offset from zero).
index=2
If no option locator prefix is provided, the default behaviour is to match on label.
$select_locator is an element locator identifying a drop-down menu
$option_locator is an option locator (a label by default)

$sel->add_selection($locator, $option_locator) Add a selection to the set of selected options in a multi-select element using an option locator.@see #doSelect for details of option locators
$locator is an element locator identifying a multi-select box
$option_locator is an option locator (a label by default)

$sel->remove_selection($locator, $option_locator) Remove a selection from the set of selected options in a multi-select element using an option locator.@see #doSelect for details of option locators
$locator is an element locator identifying a multi-select box
$option_locator is an option locator (a label by default)

$sel->get_selected_labels($select_locator) Gets all option labels (visible text) for selected options in the specified select or multi-select element.
$select_locator is an element locator identifying a drop-down menu
Returns an array of all selected option labels in the specified select drop-down

$sel->get_selected_label($select_locator) Gets option label (visible text) for selected option in the specified select element.
$select_locator is an element locator identifying a drop-down menu
Returns the selected option label in the specified select drop-down

$sel->get_selected_values($select_locator) Gets all option values (value attributes) for selected options in the specified select or multi-select element.
$select_locator is an element locator identifying a drop-down menu
Returns an array of all selected option values in the specified select drop-down

$sel->get_selected_value($select_locator) Gets option value (value attribute) for selected option in the specified select element.
$select_locator is an element locator identifying a drop-down menu
Returns the selected option value in the specified select drop-down

$sel->get_selected_indexes($select_locator) Gets all option indexes (option number, starting at 0) for selected options in the specified select or multi-select element.
$select_locator is an element locator identifying a drop-down menu
Returns an array of all selected option indexes in the specified select drop-down

$sel->get_selected_index($select_locator) Gets option index (option number, starting at 0) for selected option in the specified select element.
$select_locator is an element locator identifying a drop-down menu
Returns the selected option index in the specified select drop-down

$sel->get_selected_ids($select_locator) Gets all option element IDs for selected options in the specified select or multi-select element. 
$select_locator is an element locator identifying a drop-down menu
Returns an array of all selected option IDs in the specified select drop-down

$sel->get_selected_id($select_locator) Gets option element ID for selected option in the specified select element.
$select_locator is an element locator identifying a drop-down menu
Returns the selected option ID in the specified select drop-down

$sel->is_something_selected($select_locator) Determines whether some option in a drop-down menu is selected.
$select_locator is an element locator identifying a drop-down menu
Returns true if some option has been selected, false otherwise

$sel->get_select_options($select_locator) Gets all option labels in the specified select drop-down.
$select_locator is an element locator identifying a drop-down menu
Returns an array of all option labels in the specified select drop-down

работа, полезности, selenium, перл

Previous post Next post
Up