Confirmed users
355
edits
Nalexander (talk | contribs) |
|||
Line 206: | Line 206: | ||
=== Add a new Robocop test === | === Add a new Robocop test === | ||
# Add a Java test file named like | # Add a Java test file named like <tt>mobile/android/tests/browser/robocop/testMyThing.java</tt>. This will get your test compiled into the Robocop APK. | ||
# Add your test file/name section like | # Add your test file/name section like ''[testMyThing]'' to <tt>mobile/android/tests/browser/robocop/robocop.ini</tt>. Without this, the Robocop test harness will not know about your test! | ||
# Optionally add HTML, JS, and CSS resources to folder | # Optionally add HTML, JS, and CSS resources to folder <tt>mobile/android/tests/browser/robocop</tt>. | ||
# Run | # Run <tt>mach build</tt> to get them built/installed before running your test. | ||
# Run | # Run <tt>mach build build/mobile/robocop</tt> to update the Robocop APK. | ||
# | # Make sure you have set host binaries downloaded and configured, following [[Mobile/Fennec/Android#Host_Builds_.28MOZ_HOST_BIN.29|Host Builds (MOZ_HOST_BIN)]]. | ||
# Run | # Run <tt>mach robocop testMyThing</tt> to run your new test on your device. | ||
# Iterate! | # Iterate! | ||
Here's an [https://hg.mozilla.org/mozilla-central/rev/101feffdaed8 example patch] that adds a fairly complicated new | Here's an [https://hg.mozilla.org/mozilla-central/rev/101feffdaed8 example patch] that adds a fairly complicated new ''testSelectionCarets'' test. | ||
See also some tips on writing [[Mobile/Fennec/Android/UITest|UITest]]s. | See also some tips on writing [[Mobile/Fennec/Android/UITest|UITest]]s. |