<?php use phpdocSeleniumGenerator\models\Argument; use phpdocSeleniumGenerator\models\Method; use phpdocSeleniumGenerator\models\ReturnValue; use phpdocSeleniumGenerator\code_generator\CodeGenerator; $generator = CodeGenerator::createNew(); $methods = []; // -------------------------------------------------------------------------------- // -------------------------------------------------------------------------------- // ---- Select $mSelect = Method::createNew(); $mSelect->name = 'select'; $mSelect->type = Method::determineTypeByName($mSelect->name); $mSelect->subtype = Method::determineSubtypeByName($mSelect->name); $mSelect->description = <<<TEXT Select an option from a drop-down using an option locator. <p>Option locators provide different ways of specifying options of an HTML Select element (e.g. for selecting a specific option, or for asserting that the selected option satisfies a specification). There are several forms of Select Option Locator.</p> <ul> <li><b>label=labelPattern</b> (label=regexp:^[Oo]ther) <br/> matches options based on their labels, i.e. the visible text. (This is the default.) </li> <li><b>value=valuePattern</b> (value=other) <br/> matches options based on their values. </li> <li><b>id=id</b> (id=option1) <br/> matches options based on their ids. </li> <li><b>index=index</b> (index=2) <br/> matches an option based on its index (offset from zero). </li>