76
edits
(→Setup) |
No edit summary |
||
| Line 3: | Line 3: | ||
With advent of NativeFennec, a new framework was needed to test the UI of the Mobile Browser. Robotium was identified as a useful framework to take advantage of, but is not complete. Robocop incorporates all of Activity, Instrumentation, and Robotium Classes to inject events into the new Java front-end of Fennec. | With advent of NativeFennec, a new framework was needed to test the UI of the Mobile Browser. Robotium was identified as a useful framework to take advantage of, but is not complete. Robocop incorporates all of Activity, Instrumentation, and Robotium Classes to inject events into the new Java front-end of Fennec. | ||
= Setup = | == Setup == | ||
=== Step one: Build Native Fennec === | === Step one: Build Native Fennec === | ||
* First [https://developer.mozilla.org/en/Mozilla_Source_Code_%28Mercurial%29| grab the source] | * First [https://developer.mozilla.org/en/Mozilla_Source_Code_%28Mercurial%29| grab the source] | ||
| Line 20: | Line 20: | ||
* NOTE *: {objdir} is a placeholder; the name of your object directory should not matter. | * NOTE *: {objdir} is a placeholder; the name of your object directory should not matter. | ||
= Running tests = | == Running tests == | ||
=== Set up the MOZ_HOST_BIN environment variable === | === Set up the MOZ_HOST_BIN environment variable === | ||
| Line 38: | Line 38: | ||
<pre>TEST_PATH=testLoad make mochitest-robotium</pre> | <pre>TEST_PATH=testLoad make mochitest-robotium</pre> | ||
= Writing tests = | == Writing tests == | ||
W.I.P. | W.I.P. | ||
<pre> | <pre> | ||
| Line 45: | Line 45: | ||
</pre> | </pre> | ||
= Frequently found Errors = | == Frequently found Errors == | ||
OOM Error. This is an error found after use of Robocop frequently, but once it has happened, Fennec itself continues to crash. To fix it, simply uninstall and reinstall. This does not occur of frequent use of Robocop, as I have run 30 iterations of just robocop without it throwing this error. | OOM Error. This is an error found after use of Robocop frequently, but once it has happened, Fennec itself continues to crash. To fix it, simply uninstall and reinstall. This does not occur of frequent use of Robocop, as I have run 30 iterations of just robocop without it throwing this error. | ||
| Line 71: | Line 71: | ||
Infrequent Runtime Errors. Two have been known to occur: One, where Fennec freezes when loading a page, the other where the page loads, but has 0 content. These are worked around by restarting the test. | Infrequent Runtime Errors. Two have been known to occur: One, where Fennec freezes when loading a page, the other where the page loads, but has 0 content. These are worked around by restarting the test. | ||
= Notes | == Notes == | ||
*If you are writing tests for Robocop, see [[https://wiki.mozilla.org/Auto-tools/Projects/Robocop/WritingTests Writing Tests]] for more API information | *If you are writing tests for Robocop, see [[https://wiki.mozilla.org/Auto-tools/Projects/Robocop/WritingTests Writing Tests]] for more API information | ||
edits