QA/Execution/Web Testing/Docs/Automation/StyleGuide: Difference between revisions

Jump to navigation Jump to search
Line 77: Line 77:
     # Bad
     # Bad
     _my_locator = "css=#content>p>a"
     _my_locator = "css=#content>p>a"
</pre>
* With Webdriver, use a Python tuple locator at all times:
<pre class="brush:py;toolbar:false;">
    # Good
    _my_locator = (By.ID, "content")
</pre>
</pre>


Confirmed users
137

edits

Navigation menu