Thanks Billy! I'll give it a go
- Jason
On Apr 19, 1:28 pm, Billy bbrack...@gmail.com wrote:
Jason, here is the solution I am using, and it seems to work well. You
are basically still doing the testing on thetestthread, but when it
comes time to call theasynctaskwe switch to theuithread, and
Jason, here is the solution I am using, and it seems to work well. You
are basically still doing the testing on the test thread, but when it
comes time to call the asynctask we switch to the ui thread, and block
the testing thread. When the UI thread is done, it releases the
testing thread and you
Hi,
Missed your response. This didn't work for me unfortunately.
Interestingly if I mark the test with @UiThreadTest I get the same
deadlock behavior, which makes me wonder whether there is some sort of
JUnit test state being re-used when the test is run in a suite?
As it stands I have a bunch
OK.. So after re-thinking this I realized why the problem is
occurring, although I still do not have a solution.
When the test is running it seems to be treating itself as the main UI
thread, which would make sense since it's an
ActivityInstrumentationTestCase2. The AsyncTask performs the
JUnit test-methods in the instrumentation test-case classes always run in
another thread than the main UI thread. I run both indiviual test-cases and
test-suites (that execute lists of test-cases) and test-methods are always
called in a different thread than the background thread.
I read this
5 matches
Mail list logo