1/* 2 * Copyright (C) 2016 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17package com.android.mediaframeworktest; 18 19import com.android.mediaframeworktest.stress.Camera2CaptureRequestTest; 20import com.android.mediaframeworktest.stress.Camera2RecordingTest; 21import com.android.mediaframeworktest.stress.Camera2ReprocessCaptureTest; 22import com.android.mediaframeworktest.stress.Camera2StillCaptureTest; 23 24import junit.framework.TestSuite; 25 26import android.test.InstrumentationTestRunner; 27import android.test.InstrumentationTestSuite; 28 29/** 30 * This is Camera2 framework test runner to execute the specified test classes if no target class 31 * is defined in the meta-data or command line argument parameters. 32 */ 33public class Camera2InstrumentationTestRunner extends InstrumentationTestRunner { 34 35 @Override 36 public TestSuite getAllTests() { 37 TestSuite suite = new InstrumentationTestSuite(this); 38 // Note the following test cases are compatible with Camera API2 39 suite.addTestSuite(Camera2StillCaptureTest.class); 40 suite.addTestSuite(Camera2RecordingTest.class); 41 suite.addTestSuite(Camera2ReprocessCaptureTest.class); 42 suite.addTestSuite(Camera2CaptureRequestTest.class); 43 return suite; 44 } 45 46 @Override 47 public ClassLoader getLoader() { 48 return Camera2InstrumentationTestRunner.class.getClassLoader(); 49 } 50} 51