I want to be able to have two projects, one that contains production code and one that contains test code. This shouldn't necessarily be an Android-specific question, but I'm want to write some unit tests for some non-platform-specific Android code on the host PC.
I created a new Java project so I can run the unit tests on the PC and only include the non-platform-specific classes from the Android project. Both projects are opened in the same Eclipse workspace. I assume I need to somehow include these Android-project sources explicitly in the new project where I'll run the Junit tests, but I can't figure out how to do this.
I'm writing an Android JUnit test and want to copy/reset a test fixture file (it's an SQLite database file.) If I were within the main application, I know I could just place the file in the assets directory and use getResources().getAssets().open(sourceFile).However, this API appears to be unavailable from the ActivityInstrumentationTestCase2 class.Is there an easy way to copy a file over from the testing PC, or should I just keep a fresh copy of a test fixture on the device and copy it over a temporary file?
Is it possible to test Cyanogenmod (v.10) in a virtual environment without installing it first on my phone (sg2)? I'm really interested a ROM without touchwiz but would like to assess some features i think are missing (as i tried the android sdk emulator with JB).
If I try to use my HTC Desire to test Apps I'm developing with Eclipse, then in the screen where I can choose the emulators and connected devices, it is only listed as unknown and a few question marks. I read that on Windows you need HTC Sync respectively the drivers in this program, but how can I solve this problem on Ubuntu?
I want to create a virtual device (nexus one) with wvga800, 800x480 but when I do, I can't see the whole screen on my 13" macbook pro, and I can't scroll down to see the bottom of the screen. How can I see the bottom of my virtual phone screen?
On a relatively new emulator image (AVD) I have about 40mb of free space. How can I expand this? I tried setting the disk.cachePartition.size option, but it didn't seem to have any effect.Just to be clear.I'm talking about the "Internal phone storage" size, not the SD Card size.
I have created a small and simple android app. I tried installing it on an actual android device. But because it won't install, I created an AVD resembling my phone. I tried copying and installing app on that AVD and it still says that error. "Application xxx could not be installed on this phone".
Before I tried installing my app on the phone or AVD I following steps: 1. Exported an unsigned copy of application onto my hard-drive. 2. User jarsigner to sign the app 3. Verified with jarsigner that my app is signed properly. 4. Used zipalign to optimize the app resources.
I do not have an icon assigned to myapp but mandatory properties like version etc. have been specified properly.
I had initially developed app using 2.1 version but because of compatability issues with my phone I reverted code to compile on 1.5 and it still doesn't get installed either on AVD or my phone.
My AVD is on 2.1 though and code is compiled with 1.5.
Is there a place where I can see the logs as to why app is not getting installed.
I do some mobile browser testing in the Android web browser through the Android SDK in Linux and I have a couple of questions: Can I run an Android Virtual Device without the entire Android SDK? Can I autostart the web browser when starting an Android Virtual Device/emulator?
I have a galaxy y duos(s6102). I have my internet connection in my pc. i use internet pass through to connect my mobile to the internet. I have a wifi enabled Sony tv too. But i dont have a wifi router. My Question is that can i use my pc's internet connection to my tv through my phones wifi?
I'm trying to set up my workstation for Android development with Eclipse Galileo. I installed the latest ADT plugin and the Android SDK, but I get this error when I try to run any basic Android project I create code...
I've been programming Android in Eclipse for about a year now and I have always launched my app by right clicking on my project name in the project explorer, followed by "run as", then "Android Application". There has to be a better way...
Is there a way to change this (three mouse clicks): "Right click on project" -> "run as" -> "Android Application"
Can an android project in Eclipse be configured so that the built-in builders read from an alternative source directory? ie. "test/src" instead of "src"? and possibly even "test/res" instead of "res"? (It appears that setting dirs in the property files will only affect ant and not the built-in builders)
I have an Android Eclipse project and an associated Android Test Eclipse project checked into a subversion repository. Given a checked out working copy, how do I bring the Android Test project into an Eclipse workspace? It's easy to add the Android project to the workspace (just File->New Project->Android Project->From Existing Source and point it at the directory in the svn working copy). But, the 'New Android Test Project' does not have an option to create from existing source.
In my emulator isRecognitionAvailable method from SpeechRecognizer class returns false and also when i run VoiceRecognition.java sample code on API level 8 platform 2.2 i got "Recognizer not present" message. Any idea hints whats going on? If problem is Speech recognition is not available in my emulator then how to install it in my virtual device?
I have added a second Virtual Device to test a different screen resolution (QVGA), but now I wanna switch back to the first AVD (HVGA) again. How can I set the virtual device in Eclipse to be used by default or even specifically for my project? In the properties I can only set the API level. I also couldn't find any information in the command line tool documentation to set this manually.
My plan is to prepopulate a database on a virtual device and then include database in the distribution of my app.However, I can't find the database file.Is it on my hard disk some where?How do I get it?I tried connecting using adb, I did an "ls" and then got really scared by this obscure list of directories.
When running a virtual device, how do I get it connected to the internet? When I check the settings of the Android SDK and AVD Manager, it knows about my proxy, but when I actually run a virtual device, the browser won't even bring up the Google home page. Instead, I get the dialog box: Data Connectivity Problem 'The server failed to communicate. Try again later.' and the browser displays 'Web page not available'.
I have an existing AVD I'm running in the Android emulator, but I'd like to change its Device ID. Can this be done either in Android SDK and AVD Manager or by editing any of the files in my ~/.android directory?