greyblue9 / dexmaker

Automatically exported from code.google.com/p/dexmaker
1 stars 0 forks source link

Instructions to set up a local dev environment would be handy #8

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I'm having trouble running the unit tests for dexmaker currently. It would be 
handy if there was a wiki article that explained how to check out the source 
and set up everything in eclipse so that the unit tests can be run. 

Currently, all my tests fail like this, but I have a feeling that I'm doing 
something quite wrong. 

java.lang.reflect.InvocationTargetException
    at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.google.dexmaker.DexMakerTest.getDataDirectory(DexMakerTest.java:1819)
    at com.google.dexmaker.stock.ProxyBuilderTest.proxyFor(ProxyBuilderTest.java:778)
    at com.google.dexmaker.stock.ProxyBuilderTest.testUnboxedResult(ProxyBuilderTest.java:417)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at junit.framework.TestCase.runTest(TestCase.java:154)
    at junit.framework.TestCase.runBare(TestCase.java:127)
    at junit.framework.TestResult$1.protect(TestResult.java:106)
    at junit.framework.TestResult.runProtected(TestResult.java:124)
    at junit.framework.TestResult.run(TestResult.java:109)
    at junit.framework.TestCase.run(TestCase.java:118)
    at junit.framework.TestSuite.runTest(TestSuite.java:208)
    at junit.framework.TestSuite.run(TestSuite.java:203)
    at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
    at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: java.lang.RuntimeException: Stub!
    at android.os.Environment.getDataDirectory(Environment.java:6)
    ... 24 more

Thanks!

Original issue reported on code.google.com by MhaleK...@gmail.com on 22 May 2012 at 8:48

GoogleCodeExporter commented 8 years ago
Great idea. I suspect your current problem is that dexmaker won't work for 
running tests on the desktop. The tests must run on a device!

Original comment by limpbizkit on 1 Jul 2012 at 6:10

GoogleCodeExporter commented 8 years ago
Until I have time to put together better documentation, you should take a look 
at vogar. That's how I run the tests myself.

https://code.google.com/p/vogar/

Original comment by limpbizkit on 11 Feb 2013 at 12:03