352
edits
|  (→Variable naming:  content added) |  (→Using high-level methods:  content) | ||
| Line 102: | Line 102: | ||
| </source> | </source> | ||
| == Using high-level methods == | == Using high-level methods <jlorenzo>== | ||
| * In a test script, make sure to only have steps that are high level.  Details can be encapsulated in the helper methods. | |||
| * In a test, make sure to only have steps that are high level ( | <source python> | ||
| # good | |||
| messages.send_an_sms_to_yourself() | |||
| # bad | |||
| messages.open_sms_app() | |||
| messages.create_new_sms(receiver) | |||
| messages.type_content(content) | |||
| messages.send() | |||
| </source> | |||
| == Avoid sleep() calls <njpark> == | == Avoid sleep() calls <njpark> == | ||
| Sleep methods can be used as follows: | Sleep methods can be used as follows: | ||
edits