Update the project creation (from the command line):

- Make the distinction between the activity class name, manifest entry,
  fully-qualified name, and tested activity for the template place-holders.
  Test activity names now directly contain the full name (including the
  "Test" prefix) instead of the template adding it.
  This is required by the new 'create test-project'

- New action: create test-project
  This requires a path to the main project. It reads the package, activity
  name and target from the main project.
  The activity is read from the manifest and can be in a more complex form
  than previously expected (for instance .subpackage.MyClass, instead of
  simply MyClass). This is what required the re-work the activity related
  template place holders.
  Options:
   -m --main Location path of the project to test, relative to the new
             project [required]
   -n --name Project name
   -p --path Location path of the new project [required]

   Example: for 2 projects MyProject and MyTests located in the same folder,
            calling from their parent folder.

     android create test-project -p MyTests -m ../MyProject

- build.properties now only gets application.package for older targets
  as the new one get it directly from XPath

- Remove AndroidXPathFactory from the anttasks project as it was already
  in sdklib which is a dependency.

- Removed IntelliJ templates for the SDK. We haven't supported them for
  a while, and now that IntelliJ has built-in support for Android, it's
  not that useful anymore.

While there is the command line parameters for 'update test-project'
it's not yet implemented.

Change-Id: I663d4cb7f439bb2abfe866f893e58f4d13aff975
This commit is contained in:
Xavier Ducrohet
2009-09-25 15:52:52 -07:00
parent bad9ac7f37
commit c51d184216
19 changed files with 387 additions and 961 deletions

View File

@@ -9,13 +9,13 @@ import android.test.ActivityInstrumentationTestCase2;
* <p/>
* To run this test, you can type:
* adb shell am instrument -w \
* -e class PACKAGE.ACTIVITY_NAMETest \
* -e class ACTIVITY_FQ_NAME \
* PACKAGE.tests/android.test.InstrumentationTestRunner
*/
public class ACTIVITY_NAMETest extends ActivityInstrumentationTestCase2<ACTIVITY_NAME> {
public class ACTIVITY_CLASS_NAME extends ActivityInstrumentationTestCase2<ACTIVITY_TESTED_CLASS_NAME> {
public ACTIVITY_NAMETest() {
super("PACKAGE", ACTIVITY_NAME.class);
public ACTIVITY_CLASS_NAME() {
super("PACKAGE", ACTIVITY_TESTED_CLASS_NAME.class);
}
}