QA/Mozmill Test Automation/Test Modules Refactor: Difference between revisions

Line 125: Line 125:
* setupModule(module) and teardownModule(module) have to specify the module parameter
* setupModule(module) and teardownModule(module) have to specify the module parameter
* If variable name contains an acronym, capitalize the acronym
* If variable name contains an acronym, capitalize the acronym
* Error messages should use the following format:
** Boolean: "<element> is <state>."
** Value: "<element> is <state>: got 'value', expected 'value'"


; Needs Discussion
; Needs Discussion
Line 131: Line 134:
** We should have a module specific to loading of test files  
** We should have a module specific to loading of test files  
** We should also check how we can make sure those locations are easily replacable with other servers (apache, ...)
** We should also check how we can make sure those locations are easily replacable with other servers (apache, ...)
* Error message format
** "Expected password-save notification bar to be visible"
** Messages should be positive in nature
** <element> should be what the element represents
** <state> should be what state we expect that element to be in
** Mochitests are using: "- got XXX, expected YYY". We should show both values in the failure message. That will make it much easier to spot failures. The element itself isn't that necessary. You will see this by the line reference.
* Parameters should be named using aParam format
* Parameters should be named using aParam format
** shows that a variable inside a long function is a parameter and hasn't been declared locally
** shows that a variable inside a long function is a parameter and hasn't been declared locally
* Constant scope - should they be global and local?
* Constant scope - should they be global and local?
Confirmed users
14,525

edits