use of com.android.mediaframeworktest.CameraTestHelper in project android_frameworks_base by ParanoidAndroid.
the class CameraFunctionalTest method setUp.
protected void setUp() throws Exception {
final Semaphore sem = new Semaphore(0);
mLooperThread = new Thread() {
@Override
public void run() {
Log.v(TAG, "starting looper");
Looper.prepare();
mHandler = new Handler();
sem.release();
Looper.loop();
Log.v(TAG, "quit looper");
}
};
mLooperThread.start();
if (!sem.tryAcquire(WAIT_TIMEOUT, TimeUnit.MILLISECONDS)) {
fail("Failed to start the looper.");
}
getActivity();
super.setUp();
mCameraTestHelper = new CameraTestHelper();
}
use of com.android.mediaframeworktest.CameraTestHelper in project android_frameworks_base by ParanoidAndroid.
the class CameraPairwiseTest method setUp.
protected void setUp() throws Exception {
final Semaphore sem = new Semaphore(0);
mLooperThread = new Thread() {
@Override
public void run() {
Log.v(TAG, "starting looper");
Looper.prepare();
mHandler = new Handler();
sem.release();
Looper.loop();
Log.v(TAG, "quit looper");
}
};
mLooperThread.start();
if (!sem.tryAcquire(WAIT_TIMEOUT, TimeUnit.MILLISECONDS)) {
fail("Failed to start the looper.");
}
getActivity();
super.setUp();
mCameraTestHelper = new CameraTestHelper();
}
use of com.android.mediaframeworktest.CameraTestHelper in project android_frameworks_base by ParanoidAndroid.
the class CameraStressTest method setUp.
protected void setUp() throws Exception {
final Semaphore sem = new Semaphore(0);
mLooperThread = new Thread() {
@Override
public void run() {
Log.v(TAG, "starting looper");
Looper.prepare();
mHandler = new Handler();
sem.release();
Looper.loop();
Log.v(TAG, "quit looper");
}
};
mLooperThread.start();
if (!sem.tryAcquire(WAIT_TIMEOUT, TimeUnit.MILLISECONDS)) {
fail("Failed to start the looper.");
}
getActivity();
super.setUp();
mCameraTestHelper = new CameraTestHelper();
File stressOutFile = new File(String.format("%s/%s", Environment.getExternalStorageDirectory(), CAMERA_STRESS_OUTPUT));
mOutput = new BufferedWriter(new FileWriter(stressOutFile, true));
mOutput.write(this.getName() + "\n");
}
Aggregations