Android :: Unit Testing Android Applications And Specifically Related To Db's

Dec 18, 2009

What is the easiest way to create some kind of test harness for Android apps and to be able to visualize (even on the emulator) what is going into the db? I want to test things like constraints, look at the data, unit test methods, etc. Is there any kind of GUI tool that I can hook up to the emulator to be able to look at the db of a particular app while I'm developing/testing, or are my only options the adb shell and creating test Activities within my app?

Android :: Unit testing Android applications and specifically related to db's


Android :: Unit Testing The Platform

Jul 14, 2010

I was finally able to build and debug the android platform (the process can be seen here). Now, the question is: where are the unit tests, how do I launch them and where do I see results? And also, is there any guide to android platform architecture?

View 1 Replies View Related

Android :: Unit Testing Localizations ?

Nov 17, 2010

There is no way to load a string from a specific locale's language file.

What I want to do is run all my locales' (I have 24 of them) time format strings through unit tests to make sure they don't crash. For example, here's a date format string in French: "'Hier à ' h:mm a".

These really need to be unit tested, because translators aren't great about properly escaping these strings, causing crashes unless we manually verify every string in every language every time we get a translation pass back.

This question has a sort-of answer. Is that really the only way? Is there a better way to specify the locale of a Context in unit tests?

View 1 Replies View Related

Android :: Unit Testing With Test Only Assets

Jul 3, 2009

I my main app and tests are organized like this (standard from "android create project"): AndroidManifest.xml assets/ main app asset files src/tests/AndroidManifest.xml -- uses <instrumentation> to point to the main app assets/ -- test-specific asset files src/ Writing test cases with AndroidTestCase, I'd like to load asset files from the test-specific assets/ directory, not from the main app assets/ directory. How can I accomplish that? The normal way to load an asset would be getContext().getAssets().open ("foo.txt"), for assets/foo.txt in the main app. I assume I just have to somehow change the Context or the AssetManager to point to the test- specific assets directory, but I don't see any way to do that. I have looked into the tests/bin/MyApp-debug.apk to confirm that the test assets are in there. Now I just need a way to access them.

View 2 Replies View Related

Android :: Unit Testing A Class That Uses .os.Handler

Oct 5, 2010

I have a class that uses a Handler for a timed, asynchronous activity.

Something like this:

CODE:.................

View 11 Replies View Related

Android :: Unit Testing & Using A Different Database File

Mar 30, 2010

I'm trying to start unit testing on my application (should have done so from the beginning). I've got an Eclipse project structure set up and everything seems to work well, but...

I'm subclassing SQLiteOpenHelper to access the application database. This works well for the application, but when using the same class in the unit tests, it writes to the same database as the actual application. This is obviously rather irritating, since unit test data shows up when developing and testing the actual application.

What's the best way to make the SQLiteOpenHelper class write to a different database file when being called from the unit tests?

View 2 Replies View Related

Android :: Unit Testing A Seek Bar's Events?

Dec 6, 2009

I have a very simple activity created with one seek bar. I'm trying to figure out how best to unit test the events.

Below is how I have the seek bar wired up in my activity.

CODE:.........

So with this I have a test class that extends ActivityInstrumentationTestCase and I have test method.

Should I not be able to so something like this? Right now I'm getting Test run failed: String resource ID #0x2 with this code.

CODE:....................

View 2 Replies View Related

Android :: How To Reset/clear Application Preferences During Unit Testing

Oct 8, 2010

I want to start with a consistent test environment so I need to reset/clear my preferences. Here's the SetUp for test I have so far. It's not reporting any errors, and my tests pass, but the preferences are not being cleared.

I'm testing the "MainMenu" activity, but I temporarily switch to the OptionScreen activity (which extends Android's PreferenceActivity class.)

I do see the test correctly open the OptionScreen during the run.

CODE
:...............
StartNewActivity Code:

CODE:.................

View 1 Replies View Related

Android :: Unit Testing Project Gets A NoClassDefFoundError For 3rd Party Jars

Oct 27, 2010

I'm trying to run unit tests on my Android app and I'm getting a NoClassDefFoundError when referencing 3rd party jars.

The classes in those jars are only referenced by the app itself, not the unit tests. The jars are on the apps classpath and have been exported in the eclipse settings to allow tyhem to be found by dependant apps - which, of course, the test app is.

View 1 Replies View Related

Android :: Unit Testing SQLiteDatabase Code - How To Instantiate A DB Instance Outside The Emulator

Feb 22, 2010

I need to run unit tests for code that references SQLiteDatabase for my Android code; however all my attempts to instantiate this object outside the emulator (on my desktop machine) have failed. JDBC on Android is not being recommended on the Net, hence it's out of the question (I could have provided mock objects very easily that way).

View 2 Replies View Related

Android :: Test Data Sources In Android Unit Testing

Jan 27, 2010

I want to test parsing of data returned from server.I thought I might create several test XML files and then feed them to the sax parser which uses my custom data handler (as in the application that I test).But where should I put those test XMLs?I tried with [project_root] /res/xml, but then I get the error: android.content.res.Resources $NotFoundException: Resource ID #0x7f040000 type #0x1c is not valid at android.content. res. Resources. loadXml ResourceParser(Resources.java:1870)at android.content.res. Resources. getXml(Resources. java:779) Does that mean that the xml is invalid, or that android couldn't find the XML file?(I use the same XML that comes from the server - copied it from the firebug's net panel and pasted into the file).Can I somehow read that XML as a text file, since etContext(). getResources() .getXml (R.xml.test_response1) returns XmlResourceParser instead of String (which I'd prefer)?

View 1 Replies View Related

Android :: Android Application Unit Testing

Aug 6, 2010

I'm new to android unit testing. I'm trying to write a unit test for the Phone application:

package com.android.phone;
import android.content.Intent;
import android.net.Uri;
import android.test.ApplicationTestCase;
import android.test.suitebuilder.annotation.MediumTest;
import com.android.phone.PhoneApp;
import dalvik.annotation.TestTargetClass;...............

View 3 Replies View Related

Android :: Proxy Related Code Changes Needed In Applications

Sep 29, 2010

We recently came to know that a lot of Mobile Carries in Asia/India have proxy enabled to get Internet access via mobile. It turns out our App does not work when the phone has internet via proxy setup (APN). Does the APP need to handle proxy individually?

View 4 Replies View Related

Android :: How To Buy A Phone For Testing Applications?

Apr 12, 2010

How to buy a phone for testing applications, can anyone suggest. Other phones in market are way to expensive.

View 11 Replies View Related

Android :: Testing Applications In Mobile

Feb 2, 2009

Can I install and test the applications directly on G1 ( purchased from T-Mobile ) or I should purchase the developer version of G1 ( available from google ). Btw, I already registered for android market.

View 2 Replies View Related

Android :: What Are The Testing Tools For Applications

Jul 21, 2010

Is there any way to test the performance of the apk files or to automate the behavior of the the applications which are developed in android?

View 2 Replies View Related

Android :: Testing Applications On Device

Feb 11, 2010

I'm trying to make my application (compiled against 2.1) compatible with the 1.5 platform. I've handled all of the res/ folder issues, and have been able to run the app on all platforms without problems. I can run it fine on all emulators, and all devices/OS systems running 1.6 or higher. But on the only 1.5 device I have (HTC Hero), I get intermittent problems.

The only 1.5 device I have is an HTC Hero phone I got free at the Sprint developer conference a few months ago. When I test the app on that device, I have occasionally encountered a bug I've not seen anywhere, and can't find any information about.

I can install the application via the adb install command (although I get two messages about unknown commands), but after installing the app, the icon can disappear from the home screen, replaced either with a different icon or no icon.

When the app is launched in this state, rather than seeing my application name in the title bar, it reads "60.0dip". I don't use this value anywhere in my application.

I have never observed this problem on any other phone I've tested on (G1, myTouch, two Motorola Droids, Nexus One), but as I said I've only got one device running 1.5.

View 9 Replies View Related

Android :: Testing Applications On Non Developer's-devices

May 14, 2010

testing applications on non developer's-devices. Is there a way to do that?

View 7 Replies View Related

Android :: Testing GPS Based Applications - Phone Choice

May 11, 2009

I'd like some feedback from your experiences on the best option to test GPS based applications. I've been developing apps and in the middle of this will have to ship out to Afghanistan for a 1 year tour. Perfect opportunity to concentrate on the apps in the down-time (nothing to do stuck on a base most of the time in a 10x15 shippping container). This is bad (with bad being a relative term) from the standpoint that there are no "data" plans in Afghanistan for GSM phones. I can get GSM service but no "data" plans. If i buy a Android OS phone I'm concerned about how I can update it with new firmware and load apps. I will have wifi access, but from what I've read this will not enable a "push" of the new firmware update to the phone as if I was with T-Mobile. Any suggestions on what phone i should buy and how to "test' my applications where I can update my firmware and load my apps onto the phone?

View 2 Replies View Related

Sony Ericsson Xperia X10 :: Good Music Related Applications

Dec 1, 2010

Anyone know any good apps from Market that are good for basic music editing and play functions for X10? I already use spotify for playlists but would like to do a few other things that are not built in.

View 1 Replies View Related

Motorola Droid :: Lost All Market Links To Free Applications - ROM Related?

Jun 16, 2010

Just wanted to share this in case others experience it...I've never seen this happen before on other ROMs (currently on BB Froyo v.2). No idea if it's the fault of the ROM, or some other quirk...this happened a full day after I had installed BB v.2 over my previous install of BB v.1.

I went into the Market/Downloads view a little while ago and found that none of my free installed apps were listed, just the paid ones. All the apps were still installed on my system, but all the market links apparently had been lost. I hadn't done anything today to change my setup or configuration, but for some reason my installed free apps had disappeared. I entered and exited the market a few times, nothing changed.

Went to Titanium and did a quick backup, just to make sure that I had all my apps. Then I tried to use Titanium's market fix feature, but it said there were no market links to fix. Remembering some advice in Titanium Backup that says when restored market links aren't showing up after a restore (which I hadn't done), if you simply download and install one app from the Market it will refresh the links...I did so, and all my free installed apps showed up again in the Market/Download screen.

View 1 Replies View Related

Android :: How Marketplace Handles The Information Related To Marketplace Applications?

Jan 8, 2010

Any thought on how the Marketplace handles the information related to the marketplace applications? I wonder if the request is posted to the marketplace every time client is started or if some of the available applications data is stored locally and refreshed by the background service.

View 4 Replies View Related

Android :: Benchmarking / Stress Testing Android Applications

Jul 29, 2010

What are the third party tools available for benchmarking mobile applications. I mean stress testing, measuring how many users it can handle or the complexity of my application.

View 5 Replies View Related

Android :: Testing GPS Applications In Android Using Emulator

Dec 29, 2009

How do you test GPS applications in Android? Can we test it using the Android emulator?

View 3 Replies View Related

Android :: Testing Problem With ActivityInstrumentationTestCase2 - T - Error When Trying To Access Activity Under Testing

Feb 24, 2010

I wrote a simplest test based on android.test.ActivityInstrumentationTestCase2.

CODE:..............

View 2 Replies View Related

Android :: Avoiding Softinput Specifically In One Activity?

Sep 29, 2009

I want to avoid softinput specifically in one activity in a very specific case.

When i *long press "menu" button *softkeypad is coming irrespective of the activity.

How can i avoid this? i have tried "stateAlwaysHidden" etc for that activity. But did it work.

Al other cases ok. Just this case* long press "menu" button*.

View 6 Replies View Related

Android :: Android Functional Testing - Testing Multiple Activities

Apr 16, 2009

I've been exploring the Android test package and I'm very confused on how to implement functional testing for endpoint-to-endpoint.

Consider the example below, I have 4 activities: 1. A Contact List Activity 2. A View Contact Activity 3. An Add/Edit Contact Activity 4. A Sync Contact List activity

I want to automate a few tests that will go through multiple test cases simulating a user experience: From launching the application, to selecting 'Add contact;' opening the add contact activity, entering data, saving it, going back to the list activity, and verifying the new contact was saved properly.

As I understand it, ActivityInstrumentationTestCase<T extends Activity> and ActivityUnitTestCase<T extends Activity>, are only useful for testing single activity functionality.

But what if I need to switch between 2 or more activities inside a single functional test case?

View 5 Replies View Related

General :: App To Transfer Files (specifically MP3) From Android To IPod?

Dec 26, 2012

Just like the subject says, is there an app to transfer files (specifically mp3 files) from android to an ipod? I have used Google search to try and find an app and I have used Bump, Bluetooth, and Bluetooth file transfer.

SCH-I500

View 2 Replies View Related

Android :: Phone Recommendations That Have Specifically Ability To Call / Text?

Sep 15, 2010

I'm looking to get an Android based phone and I thought I had decided on one, but since then I keep seeing other options and I'm not sure what to go with any more. It would be nice if anyone could point me to the best option for me. The only things I'm looking for in an android phone specifically is the ability to call, text (very little chance this won't be included :P) and GPS. I do not want a high-end one, and I certainly don't want one which has an enormous screen/form like the Desire, Galaxy S or likewise. I'm looking to spend no more than �250, but would prefer the option to be sub-�200 and possible to buy in the UK. I'm not looking for a contract or branded, and want to buy it outright, so importing can be an option assuming it's not troublesome. It's important that the tech be powerful enough that the UI isn't sluggish and is fairly responsive. A nice plus would be to have WiFi capability, with it being possible to tether. The phone I was originally looking at was the HTC Wildfire, and the only downside I could find about the phone was the screen resolution. Then I seen an announcement for the new LG Optimus One and became unsure and thought there may be another better option around.

View 2 Replies View Related

Android :: Google Group Specifically For Games Development And Using OpenGL ES?

Nov 11, 2009

Is there an Android Google group specifically for games development, especially using OpenGL ES?

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved