Right. I just copy local.properties from framework, but yeah, that's one of those housekeeping steps.
On Fri, Nov 16, 2012 at 1:36 PM, Andrew Grieve <[email protected]> wrote: > I think you need to run it so that it sets the SDK path in local.properties. > > > On Fri, Nov 16, 2012 at 4:23 PM, Joe Bowser <[email protected]> wrote: >> >> The project should be updated. Do you have the latest code? >> >> On Fri, Nov 16, 2012 at 12:40 PM, Andrew Grieve <[email protected]> >> wrote: >> > Okay, actually, command line instructions were a bit off, (framework >> > directory ---> test directory) + need to adb update project. I'll >> > (update >> > wiki) >> > >> > But! Tests all passed for me except on my 4.0.1 emulator. >> > >> > >> > On Fri, Nov 16, 2012 at 2:58 PM, Andrew Grieve <[email protected]> >> > wrote: >> > >> >> Thanks Joe. Instructions look good! >> >> >> >> I asked around and got some advice for making webview's suck less in >> >> the >> >> context of destroying & recreating them: >> >> >> >> - create your WebView programmatically and not via xml layout >> >> - unregister all JS interfaces on 3.0+ via call via reflection >> >> to: type.getMethod("removeJavascriptInterface", String.class) >> >> - explicitly call WebView.destroy(), destroyDrawingCache() >> >> >> >> Not sure how necessary these things are, but they are leads anyways. >> >> >> >> >> >> On Fri, Nov 16, 2012 at 1:50 PM, Joe Bowser <[email protected]> wrote: >> >> >> >>> BTW: The Wiki has been updated: >> >>> >> >>> http://wiki.apache.org/cordova/RunningTests >> >>> >> >>> On Fri, Nov 16, 2012 at 10:49 AM, Joe Bowser <[email protected]> >> >>> wrote: >> >>> > Hey >> >>> > >> >>> > I noticed that the tests are failing. Worse, the tests are failing >> >>> > randomly and they're not failing all the time. I think we leak a >> >>> > receiver when using a CordovaWebView, so I'll have to investigate >> >>> > this, since it's causing this spectacular WebKit crash. Really, >> >>> > this >> >>> > is a pretty EPIC FAIL of WebView. I'll be looking at that. Let me >> >>> > know if you can reproduce the same epic fail on your end. >> >>> > >> >>> > On Fri, Nov 16, 2012 at 10:13 AM, Joe Bowser <[email protected]> >> >>> > wrote: >> >>> >> Honestly, running JUnit Tests in Eclipse is pretty trivial, as is >> >>> >> running these from the command line. I just tried it and here's >> >>> >> the >> >>> >> command: >> >>> >> >> >>> >> adb shell am instrument -w >> >>> >> org.apache.cordova.test/android.test.InstrumentationTestRunner >> >>> >> >> >>> >> On Thu, Nov 15, 2012 at 7:32 PM, Andrew Grieve >> >>> >> <[email protected]> >> >>> wrote: >> >>> >>> Awesome. The steps to run it in eclipse would be a good addition >> >>> >>> as >> >>> well. >> >>> >>> I'll sign up to add the iOS unit test instructions. >> >>> >>> >> >>> >>> >> >>> >>> On Thu, Nov 15, 2012 at 8:11 PM, Joe Bowser <[email protected]> >> >>> wrote: >> >>> >>> >> >>> >>>> Web Driver is not necessary to run the tests. I'll get the >> >>> >>>> command >> >>> line >> >>> >>>> version working tomorrow. >> >>> >>>> On Nov 15, 2012 5:05 PM, "Andrew Grieve" <[email protected]> >> >>> wrote: >> >>> >>>> >> >>> >>>> > Started to update wiki instructions... but what is the correct >> >>> last step? >> >>> >>>> > >> >>> >>>> > === To run these tests from the command line: === >> >>> >>>> > 1. Install "Google Web Driver" through the Android SKD Manager >> >>> >>>> > 1. Copy the >> >>> >>>> > extras/google/webdriver/android_webdriver_library.jar >> >>> from >> >>> >>>> the >> >>> >>>> > Android SDK into the framework/libs directory >> >>> >>>> > 1. Build Cordova by running "ant" from within the framework >> >>> directory >> >>> >>>> > 1. Run the following command in the framework directory with a >> >>> device >> >>> >>>> > attached or emulator running: >> >>> >>>> > adb shell am instrument -w >> >>> >>>> > com.phonegap/android.test.InstrumentationTestRunner >> >>> >>>> > >> >>> >>>> > >> >>> >>>> > >> >>> >>>> > On Wed, Nov 14, 2012 at 9:24 PM, Andrew Grieve < >> >>> [email protected]> >> >>> >>>> > wrote: >> >>> >>>> > >> >>> >>>> > > Tried to follow the command-line instructions but get: >> >>> >>>> > > >> >>> >>>> > > >> >>> >>>> > > agrieve@dhcp-172-23-181-44~/git/incubator-cordova-android/framework >> >>> >>>> > > (asdf) $ adb shell am instrument -w >> >>> >>>> > > com.phonegap/android.test.InstrumentationTestRunner >> >>> >>>> > > INSTRUMENTATION_STATUS: id=ActivityManagerService >> >>> >>>> > > INSTRUMENTATION_STATUS: Error=Unable to find instrumentation >> >>> info for: >> >>> >>>> > > >> >>> ComponentInfo{com.phonegap/android.test.InstrumentationTestRunner} >> >>> >>>> > > INSTRUMENTATION_STATUS_CODE: -1 >> >>> >>>> > > android.util.AndroidException: INSTRUMENTATION_FAILED: >> >>> >>>> > > com.phonegap/android.test.InstrumentationTestRunner >> >>> >>>> > > >> >>> >>>> > > Changing to org.apache.cordova: >> >>> >>>> > > >> >>> >>>> > > agrieve@dhcp-172-23-181-44~/git/incubator-cordova-android/framework >> >>> >>>> > > (asdf) $ adb shell am instrument -w >> >>> >>>> > > org.apache.cordova/android.test.InstrumentationTestRunner >> >>> >>>> > > android.util.AndroidException: INSTRUMENTATION_FAILED: >> >>> >>>> > > org.apache.cordova/android.test.InstrumentationTestRunner >> >>> >>>> > > >> >>> >>>> > > On Wed, Nov 14, 2012 at 4:41 PM, Simon MacDonald < >> >>> >>>> > > [email protected]> wrote: >> >>> >>>> > > >> >>> >>>> > >> Yup, it passed when I ran it and only it. >> >>> >>>> > >> >> >>> >>>> > >> Simon Mac Donald >> >>> >>>> > >> http://hi.im/simonmacdonald >> >>> >>>> > >> >> >>> >>>> > >> >> >>> >>>> > >> On Wed, Nov 14, 2012 at 4:35 PM, Joe Bowser >> >>> >>>> > >> <[email protected]> >> >>> >>>> wrote: >> >>> >>>> > >> >> >>> >>>> > >> > How can testPreconditions fail, but testViaLoadUrl pass? >> >>> >>>> > >> > Can >> >>> you run >> >>> >>>> > >> > the test by itself? testViaHref is known to fail, and >> >>> >>>> > >> > there's >> >>> an >> >>> >>>> issue >> >>> >>>> > >> > open about that bug. >> >>> >>>> > >> > >> >>> >>>> > >> >> >>> >>>> > > >> >>> >>>> > > >> >>> >>>> > >> >>> >>>> >> >>> >> >> >> >> > >
