QA SoftVision Team/Mobile/Writing tests: Difference between revisions

Jump to navigation Jump to search
Undo revision 517137 by Csuciu (talk)
(Undo revision 517137 by Csuciu (talk))
Line 27: Line 27:
  hg qpop
  hg qpop


#filter substitution
= Basic structure of the test =
package @ANDROID_PACKAGE_NAME@.tests;


  import @ANDROID_PACKAGE_NAME@.*;
package org.mozilla.fennec_root.tests; // Robotium test package
  import org.mozilla.fennec_root.*; // import the package in order to be able to reuse classes if needed
   
   
  /*
  /*
Line 57: Line 58:
* If your tests extends BaseTest then you will not need to add the methods setUp() and tearDown() as they are already defined in BaseTest
* If your tests extends BaseTest then you will not need to add the methods setUp() and tearDown() as they are already defined in BaseTest
* If you need to do extra clean-up, like removing entries you added in a database for e.g., the tearDown() method can be overwrittern but make sure to call '''super.tearDown()''' as needed in the method. The same is applicable for setUp().
* If you need to do extra clean-up, like removing entries you added in a database for e.g., the tearDown() method can be overwrittern but make sure to call '''super.tearDown()''' as needed in the method. The same is applicable for setUp().
= APIs  =
= APIs  =
Robotium itself provides a rich API through the Solo class - javadocs for Solo are available at [1].
Robotium itself provides a rich API through the Solo class - javadocs for Solo are available at [1].
Confirmed users
1,620

edits

Navigation menu