This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Journey To Enterprise Agility and have Daryl Kulak & Hong Li on-line!
See this thread for details.
Win a copy of The Journey To Enterprise Agility this week in the Agile and Other Processes forum! And see the welcome thread for 20% off.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
Sheriffs:
  • Paul Clapham
  • Junilu Lacar
  • Knute Snortum
Saloon Keepers:
  • Ron McLeod
  • Ganesh Patekar
  • Tim Moores
  • Pete Letkeman
  • Stephan van Hulst
Bartenders:
  • Carey Brown
  • Tim Holloway
  • Joe Ess

A fatal error has been detected by the Java Runtime Environment: ADT Eclipse  RSS feed

 
Greenhorn
Posts: 21
Fedora Java ME Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am getting the following error whenever i am compiling the class with ADT eclipse.
This class running fine with the normal version of eclipse.

# # A fatal error has been detected by the Java Runtime Environment: #
# Internal Error (classFileParser.cpp:3470), pid=3172, tid=3816 # Error: ShouldNotReachHere() #
# JRE version: 7.0-b147 # Java VM: Java HotSpot(TM) 64-Bit Server VM (21.0-b17 mixed mode windows-amd64 compressed oops)
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows #
# An error report file with more information is saved as:
# C:\Users\Rohit\ ANDROID workspace\NASADailyImage\hs_err_pid3172.log # # If you would like to submit a bug report, please visit:
# http://bugreport.sun.com/bugreport/crash.jsp #


I dont know whats going on. I need to use SAX in my android app.This being my first app,i dont know whats the problem.
please help guys.




Thank you for you help in advance.
 
Bartender
Posts: 4181
22
IntelliJ IDE Java Python
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you trying to run the application as a normal Java app? You can't do that - I believe the files are further compiled whenever they are part of an Android project and the resulting byte code can not be run in a normal JRE. For testing purposes (before bringing it to the emulator) it is best to get the Android Unit Test framework and run the tests from there.
 
Rohit Savant
Greenhorn
Posts: 21
Fedora Java ME Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes i was trying to run it as normal java program for testing purposes. I didnt knew the code will get converted to dex code even without emulator.
I have never used Android Unit Test framework. I will try to learn how to use it. If anybody has good sources from where to learn test framework please tell me.And a good android book if possible.

Thankyou
 
Steve Luke
Bartender
Posts: 4181
22
IntelliJ IDE Java Python
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Rohit Savant wrote:Yes i was trying to run it as normal java program for testing purposes. I didnt knew the code will get converted to dex code even without emulator.
I have never used Android Unit Test framework. I will try to learn how to use it. If anybody has good sources from where to learn test framework please tell me.And a good android book if possible.

Thankyou



I have been using Android In Action (on Amazon) to learn. It does not cover unit testing, though.

See the android network for instructions on how to use Android UnitTest framework with eclipse. It isn't hard. It basically comes down to:

* Write the code you want as part of the application in your main Android project
* Create an Android UnitTest project (make sure you add reference to the main Android project)
* Create a Test class that extends one of the Android TestCase classes. See the API for TestCase for some examples
** For POJO-type testing, I use the base TestCase class.
** For testing Activity or Service life cycles I use the appropriate extensions
* Methods that you want to run as tests should start with the name test.
* Methods should be short, test one aspect of the program.
* you should include tests which will break the code to make sure you handle them
* TestCase has a series of Assert functions you use to make sure you get the expected results.

edit:
I forgot - you run the Android Test project, not the main Android project.
 
Rohit Savant
Greenhorn
Posts: 21
Fedora Java ME Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you Steve.!
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!