FileDocCategorySizeDatePackage
MessengerTest.javaAPI DocAndroid 1.5 API3841Wed May 06 22:42:02 BST 2009com.android.unit_tests.os

MessengerTest

public class MessengerTest extends android.test.AndroidTestCase

Fields Summary
private android.os.Messenger
mServiceMessenger
private android.content.ServiceConnection
mConnection
Constructors Summary
Methods Summary
protected voidsetUp()

        super.setUp();
        getContext().bindService(new Intent(mContext, MessengerService.class),
                mConnection, Context.BIND_AUTO_CREATE);
        synchronized (this) {
            while (mServiceMessenger == null) {
                try {
                    wait();
                } catch (InterruptedException e) {
                }
            }
        }
    
protected voidtearDown()

        super.tearDown();
        getContext().unbindService(mConnection);
    
public voidtestSend()

        (new TestThread()).doTest(1000);