ant scripts to build apk file and load it in a emulator?

by jrichards1...@googlemail.com » Mon, 19 Jul 2010 16:52:20 GMT


Sponsored Links
 i.

i am trying to create a build.xml script that cleans, builds and
creates a apk file of a Junit android test project that i have
created.

the steps i want to achieve in my build file is this:

[list=]clean[/list]
[list=]build[/list]
[list=]create apk file[/list]
[list=]Sign apk file[/list]
[list=]launch emulator[/list]
[list=]install apk file[/list]
[list=]run instrumentalTest[/list]
[list=]Save the tests into an HTML Junit Report[/list]

Anyone know how to achieve this? so far my build file looks like this:

[code]<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- WARNING: Eclipse auto-generated file.
Any modifications will be overwritten.
To include a user specific buildfile here, simply

create one in the same
directory with the processing instruction <?

eclipse.ant.import?>
as the first entry and export the buildfile again.

-->
<project basedir="." default="build" name="Unity Agent SDK Test">
<property environment="env" />
<property name="junit.output.dir" value="junit" />
<property name="debuglevel" value="source,lines,vars" />
<property name="target" value="1.6" />
<property name="source" value="1.6" />
<property file="build.properties" />
<path id="android1.6.userclasspath">
<pathelement location="lib/android.jar" />
</path>
<path id="Junit.userclasspath">
<pathelement location="lib/junit-4.8.2" />
<pathelement location="lib/
org.hamcrest.core_1.1.0.v20090501071000.jar" />
</path>
<path id="Unity Agent SDK Test.classpath">
<pathelement location="bin" />
<pathelement location="lib/fb_connect-android-api.jar" />
<pathelement location="lib/signpost-commonshttp4-1.2.jar" />
<pathelement location="lib/signpost-core-1.2.jar" />
<pathelement location="lib/UnityAgentSDK.jar" />
<path refid="android1.6.userclasspath" />
<path refid="Junit.userclasspath" />
</path>

<path id="android.antlibs">
<pathelement path="${android-sdk-path}/tools/lib/anttasks.jar"
/>
<pathelement path="${android-sdk-path}/tools/lib/sdklib.jar" />
<pathelement
path="${android-sdk-path}/tools/lib/androidprefs.jar" /
<pathelement
path="${android-sdk-path}/tools/lib/apkbuilder.jar" />
<pathelement path="${android-sdk-path}/tools/lib/jarutils.jar"
/>
</path>

<path id="run.Unity Agent SDK Test (1).classpath">
<path refid="Unity Agent SDK Test.classpath" />
</path>
<path id="run.Unity Agent SDK Test (1).bootclasspath" />
<target name="init



Other Threads

1. onClick for ExpandableListAdapter

I would like to invoke a function when a child is clicked within a
ExpandableListAdapter

The children are ViewHolders.

Below is my getChildView from myExpandableListAdapter class.

it reacts to Long clicks, but i can't figure out how to also get it to
react to a short click.

Thanks
Kevin

public View getChildView(int groupPosition, int childPosition,
                                boolean isLastChild, View convertView, 
ViewGroup parent) {

                        ViewHolder holder;
                        if (convertView == null) {
                                convertView = 
mInflater.inflate(R.layout.listview, null);
                                holder = new ViewHolder();
                                holder.text = (TextView) convertView
                                                .findViewById(R.id.TextView01);
                                holder.text2 = (TextView) convertView
                                                .findViewById(R.id.TextView02);
                                holder.text3 = (TextView) convertView
                                                .findViewById(R.id.TextView03);
                                convertView.setTag(holder);
                        } else {
                                convertView.setClickable(true);
                                holder = (ViewHolder) convertView.getTag();
                        }


                        
holder.text.setText(children.get(groupPosition).get(childPosition)
                                        .get(0));
                        
holder.text2.setText(children.get(groupPosition).get(childPosition)
                                        .get(1));
                        
holder.text3.setText(children.get(groupPosition).get(childPosition)
                                        .get(2));

                        return convertView;
                }

-- 

2. Want to write a forum reader

Hi,

I've done some Android programming and 2 apps on the market. I'm now
thinking to write a simplified mobile reader for a forum. Can anyone
give me some light what is involve and generally how to do it?

1. What is it involve to do web sign in? http? any example/code
documentation to study?
2. Formating of forum message to the mobile edition?

General ideal which direction to find so I can do the research.

Rgds,
CJ

-- 

3. contact on SGS

4. Keunggulan Android dan Google

5. Test roti djahe on moto droid 1

6. Sansui MiniPad 7" LAN Problem

7. SQLite Encryption