You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: AutoCheck.md
+9-9
Original file line number
Diff line number
Diff line change
@@ -22,16 +22,16 @@ Standard PHP detection class supports this (which works with [Xdebug](http://xde
22
22
Positive checks validate that the page contains elements that match given selector(s). However, it can't validate that HTML of a page conforms to HTML standard. That's because Firefox automatically fixes incorrect HTML and it adds missing necessary elements.
23
23
24
24
## Configuration ##
25
-
Configure these checks at {{chromeUrl}} _chrome://selite-settings/content/tree.xul?module=extensions.selite-settings.common_. In order to use [AutoCheck](AutoCheck) you must select at least `autoCheckDetector` or `autoCheckDetectorCustom`. Other fields are optional.<!-- TODO format options as `code`-->
25
+
Configure these checks at {{chromeUrl}} _chrome://selite-settings/content/tree.xul?module=extensions.selite-settings.common_. In order to use [AutoCheck](AutoCheck) you must select at least `autoCheckDetector` or `autoCheckDetectorCustom`. Other fields are optional.
26
26
27
-
* autoCheckAssert - whether an occurrence should trigger an assert failure; by default it triggers a validation failure rather than an assert failure
28
-
* autoCheckDetector - choose a standard detection class to use; or set it to null/undefined if you use a custom class
29
-
* autoCheckDetectorCustom - enter a name of the custom detection class (which you must load into [Core scope] e.g. via [Bootstrap](Bootstrap)); used only if autoCheckDetector is null/undefined
30
-
* autoCheckIgnored - the format of entries depends on the detection class. [AutoCheck](AutoCheck) reports failures unless they match an autoCheckIgnored entry. Use autoCheckIgnored to match already reported bugs (so that they don't get reported again).
27
+
*`autoCheckAssert` - whether an occurrence should trigger an assert failure; by default it triggers a validation failure rather than an assert failure
28
+
*`autoCheckDetector` - choose a standard detection class to use; or set it to `null` or `undefined` if you use a custom class
29
+
*`autoCheckDetectorCustom` - enter a name of the custom detection class (which you must load into [Core scope] e.g. via [Bootstrap](Bootstrap)); used only if `autoCheckDetector` is `null` or `undefined`
30
+
*`autoCheckIgnored` - the format of entries depends on the detection class. [AutoCheck](AutoCheck) reports failures unless they match an `autoCheckIgnored` entry. Use `autoCheckIgnored` to match already reported bugs (so that they don't get reported again).
31
31
* for PHP enter XPath logical conditions (not whole XPath expressions). Those would match either PHP warning/notice/error message (description) or a leaf file path (where the failure occurred). The conditions can refer to that text node by '.' (and they must not refer to parent/sibling nodes). Examples are
32
-
* contains(., 'Undefined variable')
33
-
* contains(., 'dbadmin.inc')
34
-
* autoCheckRefused - enter locator(s) to be refused; none of the locator(s) must match any element, otherwise the page fails
35
-
* autoCheckRequired - enter locator(s) to be required; each locator must match at least one element, otherwise the page fails
32
+
*`contains(., 'Undefined variable')`
33
+
*`contains(., 'dbadmin.inc')`
34
+
*`autoCheckRefused` - enter locator(s) to be refused; none of the locator(s) must match any element, otherwise the page fails
35
+
*`autoCheckRequired` - enter locator(s) to be required; each locator must match at least one element, otherwise the page fails
36
36
37
37
(Those fields are not defined in _chrome://selite-settings/content/common\_settings\_module.js_. Instead, they are added on the fly by _chrome://selite-auto-check/content/SeLiteExtensionSequencerManifest.js_).
If you introduce or modify any Selenese [commands][command] - i.e. <code>Selenium.prototype.do<em>Xyz</em>, Selenium.prototype.get<em>Xyz</em></code> or <code>Selenium.prototype.is<em>Xyz</em></code> - then those will be available to your [case]/[suite] only **after** you run any Selenese command first.<!-- TODO don't know why -->
46
+
If you introduce or modify any Selenese [commands][command] - i.e. <code>Selenium.prototype.do<em>Xyz</em>, Selenium.prototype.get<em>Xyz</em></code> or <code>Selenium.prototype.is<em>Xyz</em></code> - then those will be available to your [case]/[suite] only **after** you run any Selenese command first.
47
47
48
48
## Switching between files ##
49
49
If you remove a filename from `bootstrapCoreExtensions` (or you switch to a different default [set] or a [suite] with a different [set] associated with it), Bootstrap can't 'unload' a file that it has loaded already. If you change that option later and you add the filename back, it won't re-run the file, unless its timestamp has changed.
Copy file name to clipboardExpand all lines: ClassicSelenese.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,7 @@ These notes on Selenese syntax are on top of [Selenium documentation](http://doc
12
12
# Auto-generated Selenese commands #
13
13
Selenese [commands][command] are defined in these primary forms: <code>xyz, <strong>get</strong>Xyz, <strong>is</strong>Xyz</code> or <code><strong>is</strong>Xyz<strong>Present</strong></code>. Selenium auto-generates their variations (listed below).
14
14
15
-
Selenium IDE shows the original reference for both the primary and auto-generated commands. However, the online reference contains only the primary commands. So if you'd like to locate them online (or in the source), use the following. (See also `loadSeleniumCommands()` in Selenium IDE's `treeView.js`.<!-- TODO link to chrome & SE IDE Github-->)
15
+
Selenium IDE shows the original reference for both the primary and auto-generated commands. However, the online reference contains only the primary commands. So if you'd like to locate them online (or in the source), use the following. (See also `loadSeleniumCommands()` in Selenium IDE's `treeView.js`.<!-- TODO link to chrome & SE IDE Github and/or selite.github.io/API-->)
16
16
17
17
<tableclass="table">
18
18
<thead>
@@ -108,7 +108,7 @@ Find a basic example at Selenium Documentation > [Test Design Considerations](ht
108
108
## Stored variables
109
109
Some Selenese [commands][command] store variables, to be used by later steps. [SelBlocksGlobal](SelBlocksGlobal) manages scope of such variables. When inside a [SelBlocksGlobal](SelBlocksGlobal) function, you can only use stored variables set in that function (or passed as parameters to it). The local scope also means: if you set a stored variable within a Selenese function and the same stored variable exists in the caller scope (that invoked the current function), the variable in the caller scope won't be affected.
110
110
111
-
<!-- TODO Put an explicit rule first, then details. Merge/link to EnhancedSyntax: -->Parameters of Selenese commands can access stored variables as `${name-of-the-variable}`. Those get replaced by the value of the variable. However, if a command processes the parameter as a Javascript expression (e.g. `storeEval, getEval` or when using [EnhancedSelenese](EnhancedSelenese)), and if the variable contains an array/object or a non-numeric string (possibly with an apostrophe or quotation mark), then replacement of `${name-of-the-variable}` won't work robustly. For those cases use `storedVars.name-of-the-variable` or `storedVars['name-of-the-variable']`. See also [EnhancedSelenese](EnhancedSelenese).
111
+
Parameters of Selenese commands can access stored variables as `${name-of-the-variable}`. Those get replaced by the value of the variable. However, if a command processes the parameter as a Javascript expression (e.g. `storeEval, getEval` or when using [EnhancedSelenese](EnhancedSelenese)), and if the variable contains an array/object or a non-numeric string (possibly with an apostrophe or quotation mark), then replacement of `${name-of-the-variable}` won't work robustly. For those cases use `$name-of-the-variable` (or `storedVars.name-of-the-variable` or `storedVars['name-of-the-variable']`). See also [EnhancedSelenese](EnhancedSelenese).
112
112
113
113
## Javascript variables
114
114
Sometimes you want a _global_ variable that spreads across Selenese functions (which stored variables can't). Use _native_ Javascript variables for it. Set them using [command]`getEval` with `target` being: `variable1=valueOrExpression, variable2=valueOrExpression....`
Copy file name to clipboardExpand all lines: DocumentationStandard.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -44,7 +44,7 @@ SeLite doesn't use GitHub Wiki, which doesn't utilise screen well, especially on
44
44
## Drawn diagrams
45
45
Don't use UML tools, as they are more restrictive and less efficient. <!-- That"s why I didn"t consider using e.g. http://plantuml.sourceforge.net and http://sourceforge.net/projects/plantumlnb -->
46
46
47
-
Draw diagrams in LibreOffice/OpenOffice and save them as `.odg`. Then Edit > Select All; File > Export (export the selection, rather than the whole drawing area). Export as a .png, not interlaced, with lowest compression. Then commit both .odg and .png to git. TODO: In documentation use URLs to the .png images from git ([selite/diagrams/](https://github.com/selite/selite/tree/master/diagrams) > navigate to `.png` file > get URL of 'Raw' button).
47
+
Draw diagrams in LibreOffice/OpenOffice and save them as `.odg`. Then Edit > Select All; File > Export (export the selection, rather than the whole drawing area). Export as a .png, not interlaced, with lowest compression. Then commit both .odg and .png to git. In documentation use URLs of 'Raw' images from git (e.g. [selite/diagrams/](https://github.com/selite/selite/tree/master/diagrams) > navigate to `.png` file > get URL of 'Raw' button).
48
48
49
49
### Versions of LibreOffice
50
50
* LibreOffice version that came with CentOS 6.4 didn't export as `.png` well - the quality was low.
@@ -58,7 +58,7 @@ Please
58
58
* use colours black, Chart 11 for red, Green 4, Chart 12 for blue, Chart 3 for yellow
59
59
60
60
## Textual object diagrams
61
-
Object Diagrams draw ownership/reference relationships between objects, fields and functions. They usually don't necessarily describe class inheritance (which is clear from the source<!--TODO: and from Javadoc -->).
61
+
Object Diagrams draw ownership/reference relationships between objects, fields and functions. They usually don't necessarily describe class inheritance (which is clear from the source and from [API]).
62
62
63
63
Text diagrams don't need to be esthetic, but clear and easy to edit - so you can quickly update them whenever you change the relevant code. They are in plain text, with **`<, >, ^, v`** for connections. The diagrams look like this:
Copy file name to clipboardExpand all lines: PackagedScripts.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -26,7 +26,7 @@ Selenium IDE doesn't indicate the current [suite]'s folder in the GUI. Therefore
26
26
27
27
Reasoning: A case can open local pages relative to its location, or to location of the current suite (the one loaded). Either choice has some positives, and can also be confusing. However, using URLs relative to the current suite allows flexible re-use of automation cases and their Selenese functions, with customised versions of local pages for each [suite]. If all such suites can use same version of a local page, such a file can be in a common parent folder. This results in similar suites having the same folder structure and same names for local pages, which simplifies navigation.
28
28
29
-
[Suites][suite] that share [cases][case] from parent folder(s) should be at the same directory depth, so that they can access any local `.html` files in higher folders through same relative URLs (e.g. `../page.html`). Scripts open local forms/pages by e.g. <!-- TODO check/FIX--> <code>open | file://` SeLiteSettings.getTestSuiteFolder() `/form.html</code>
29
+
[Suites][suite] that share [cases][case] from parent folder(s) should be at the same directory depth, so that they can access any local `.html` files in higher folders through same relative URLs (e.g. `../page.html`). Scripts open local forms/pages by e.g. `open | file://<> SeLiteSettings.getTestSuiteFolder() <>/form.html`.
30
30
31
31
We indent commands in tests. That requires [SeLite Clipboard And Indent](https://addons.mozilla.org/en-US/firefox/addon/selite-clipboard-and-indent/). Otherwise run `sed -r -e 's/<td>( )+/<td>/' test-case-location >temp_out; cp temp_out >test-case-location`.
0 commit comments