media bitstreams test: split into classes based on path prefix
Bug: 62976713
Test: cts-tradefed run cts -m CtsMediaBitstreamsTestCases
Change-Id: Iaf8e8b6f56c5692c0c87f878efa35f571325ce50
diff --git a/hostsidetests/media/bitstreams/AndroidTest.xml b/hostsidetests/media/bitstreams/AndroidTest.xml
index c291b77..71c8519 100644
--- a/hostsidetests/media/bitstreams/AndroidTest.xml
+++ b/hostsidetests/media/bitstreams/AndroidTest.xml
@@ -26,5 +26,7 @@
<test class="com.android.compatibility.common.tradefed.testtype.JarHostTest" >
<option name="jar" value="CtsMediaBitstreamsTestCases.jar" />
<option name="runtime-hint" value="4h50m" />
+ <!-- shard-unit must be class -->
+ <option name="shard-unit" value="class" />
</test>
</configuration>
diff --git a/hostsidetests/media/bitstreams/common/src/android/media/cts/bitstreams/MediaBitstreams.java b/hostsidetests/media/bitstreams/common/src/android/media/cts/bitstreams/MediaBitstreams.java
index 99c4387..774e5be 100644
--- a/hostsidetests/media/bitstreams/common/src/android/media/cts/bitstreams/MediaBitstreams.java
+++ b/hostsidetests/media/bitstreams/common/src/android/media/cts/bitstreams/MediaBitstreams.java
@@ -53,6 +53,7 @@
public static final String K_TEST_GET_SUPPORTED_BITSTREAMS = "testGetSupportedBitstreams";
public static final String K_NATIVE_CRASH = "native crash";
public static final String K_UNSUPPORTED = "unsupported";
+ public static final String K_UNAVAILABLE = "unavailable";
public static final String DYNAMIC_CONFIG_XML = "DynamicConfig.xml";
public static final String DYNAMIC_CONFIG = "dynamicConfig";
@@ -67,7 +68,7 @@
* @return checksum file path for {@code bitstreamPath}, e.g. {@code h264/../../../../*_md5}.
*/
public static String getMd5Path(String bitstreamPath) {
- String base = bitstreamPath.split("\\.")[0];
+ String base = bitstreamPath.replaceAll(".mp4$|.webm$", "");
String codec = bitstreamPath.split("/", 2)[0];
String md5Path = String.format("%s_%s_md5", base, codec);
return md5Path;
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitBpBitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitBpBitstreamsTest.java
new file mode 100644
index 0000000..b1a1c05
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitBpBitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class H264Yuv420_8bitBpBitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("h264/yuv420/8bit/bp");
+ }
+
+ public H264Yuv420_8bitBpBitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitHpBitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitHpBitstreamsTest.java
new file mode 100644
index 0000000..4d4d1cb
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitHpBitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class H264Yuv420_8bitHpBitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("h264/yuv420/8bit/hp");
+ }
+
+ public H264Yuv420_8bitHpBitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitMpBitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitMpBitstreamsTest.java
new file mode 100644
index 0000000..baa10c1
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/H264Yuv420_8bitMpBitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class H264Yuv420_8bitMpBitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("h264/yuv420/8bit/mp");
+ }
+
+ public H264Yuv420_8bitMpBitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv400BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv400BitstreamsTest.java
new file mode 100644
index 0000000..87a045c
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv400BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class HevcYuv400BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("hevc/yuv400");
+ }
+
+ public HevcYuv400BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv420BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv420BitstreamsTest.java
new file mode 100644
index 0000000..189b368
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv420BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class HevcYuv420BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("hevc/yuv420");
+ }
+
+ public HevcYuv420BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv422BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv422BitstreamsTest.java
new file mode 100644
index 0000000..5cc0131
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv422BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class HevcYuv422BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("hevc/yuv422");
+ }
+
+ public HevcYuv422BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv444BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv444BitstreamsTest.java
new file mode 100644
index 0000000..38391b5
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/HevcYuv444BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class HevcYuv444BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("hevc/yuv444");
+ }
+
+ public HevcYuv444BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/MediaBitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/MediaBitstreamsTest.java
index 2c61859..41cb5c9 100644
--- a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/MediaBitstreamsTest.java
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/MediaBitstreamsTest.java
@@ -39,6 +39,7 @@
import java.nio.file.Files;
import java.util.ArrayDeque;
import java.util.ArrayList;
+import java.util.Collection;
import java.util.Collections;
import java.util.Deque;
import java.util.HashMap;
@@ -48,11 +49,10 @@
import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.ConcurrentMap;
import org.junit.Ignore;
import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized.Parameters;
-import org.junit.runners.Parameterized.UseParametersRunnerFactory;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
import org.xmlpull.v1.XmlPullParserFactory;
@@ -61,9 +61,7 @@
* Test that verifies video bitstreams decode pixel perfectly
*/
@OptionClass(alias="media-bitstreams-test")
-@RunWith(DeviceJUnit4Parameterized.class)
-@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
-public class MediaBitstreamsTest implements IDeviceTest, IBuildReceiver, IAbiReceiver {
+public abstract class MediaBitstreamsTest implements IDeviceTest, IBuildReceiver, IAbiReceiver {
@Option(name = MediaBitstreams.OPT_HOST_BITSTREAMS_PATH,
description = "Absolute path of Ittiam bitstreams (host)",
@@ -95,6 +93,32 @@
description = "Only test bitstreams in this sub-directory")
private String mPrefix = "";
+ private String mPath = "";
+
+ private static ConcurrentMap<String, List<ConformanceEntry>> mResults = new ConcurrentHashMap<>();
+
+ /**
+ * Which subset of bitstreams to test
+ */
+ enum BitstreamPackage {
+ SMALL,
+ STANDARD,
+ FULL,
+ }
+
+ static class ConformanceEntry {
+ final String mPath, mCodecName, mStatus;
+ ConformanceEntry(String path, String codecName, String status) {
+ mPath = path;
+ mCodecName = codecName;
+ mStatus = status;
+ }
+ @Override
+ public String toString() {
+ return String.format("%s,%s,%s", mPath, mCodecName, mStatus);
+ }
+ }
+
/**
* A helper to access resources in the build.
*/
@@ -103,24 +127,25 @@
private IAbi mAbi;
private ITestDevice mDevice;
- @Parameters(name = "{0}")
- public static Iterable<? extends Object> bitstreams() {
+ static Collection<Object[]> bitstreams(String prefix) {
final String dynConfXml = new File("/", MediaBitstreams.DYNAMIC_CONFIG_XML).toString();
try (InputStream is = MediaBitstreamsTest.class.getResourceAsStream(dynConfXml)) {
- List<String> entries = new ArrayList<>();
+ List<Object[]> entries = new ArrayList<>();
XmlPullParser parser = XmlPullParserFactory.newInstance().newPullParser();
parser.setInput(is, null);
parser.nextTag();
parser.require(XmlPullParser.START_TAG, null, MediaBitstreams.DYNAMIC_CONFIG);
while (parser.next() != XmlPullParser.END_DOCUMENT) {
- if (parser.getEventType() != XmlPullParser.START_TAG) {
+ if (parser.getEventType() != XmlPullParser.START_TAG
+ || !MediaBitstreams.DYNAMIC_CONFIG_ENTRY.equals(parser.getName())) {
continue;
}
- String name = parser.getName();
- if (name.equals(MediaBitstreams.DYNAMIC_CONFIG_ENTRY)) {
- final String key = MediaBitstreams.DYNAMIC_CONFIG_KEY;
- entries.add(parser.getAttributeValue(null, key));
+ final String key = MediaBitstreams.DYNAMIC_CONFIG_KEY;
+ String bitstream = parser.getAttributeValue(null, key);
+ if (!bitstream.startsWith(prefix)) {
+ continue;
}
+ entries.add(new Object[] {prefix, bitstream});
}
return entries;
} catch (XmlPullParserException | IOException e) {
@@ -129,8 +154,9 @@
}
}
- public MediaBitstreamsTest(String prefix) {
+ public MediaBitstreamsTest(String prefix, String path) {
mPrefix = prefix;
+ mPath = path;
}
@Override
@@ -190,6 +216,10 @@
report.addValue(MediaBitstreams.KEY_CODEC_NAME, d, ResultType.NEUTRAL, ResultUnit.NONE);
report.addValue(MediaBitstreams.KEY_STATUS, s, ResultType.NEUTRAL, ResultUnit.NONE);
report.submit();
+
+ ConformanceEntry ce = new ConformanceEntry(p, d, s);
+ mResults.putIfAbsent(p, new ArrayList<>());
+ mResults.get(p).add(ce);
}
Map<String, String> getArgs() {
@@ -368,9 +398,16 @@
}
@Test
- public void testBitstreamsConformance()
- throws DeviceNotAvailableException, IOException {
- testBitstreamsConformance(mPrefix);
+ public void testBitstreamsConformance() {
+ if (!mResults.containsKey(mPath)) {
+ try {
+ testBitstreamsConformance(mPrefix);
+ } catch (DeviceNotAvailableException | IOException e) {
+ String curMethod = getCurrentMethod();
+ addConformanceEntry(curMethod, mPath, MediaBitstreams.K_UNAVAILABLE, e.toString());
+ }
+ }
+ // todo(robertshih): lookup conformance entry; pass/fail based on lookup result
}
private void testBitstreamsConformance(String prefix)
@@ -383,7 +420,7 @@
device,
MediaBitstreams.K_TEST_GET_SUPPORTED_BITSTREAMS,
MediaBitstreams.KEY_SUPPORTED_BITSTREAMS_TXT);
- Set<String> bitstreams = preparer.getBitstreams();
+ Collection<Object[]> bitstreams = bitstreams(mPrefix);
Set<String> supportedBitstreams = preparer.getSupportedBitstreams();
CLog.i("%d supported bitstreams under %s", supportedBitstreams.size(), prefix);
@@ -393,7 +430,7 @@
String curMethod = getCurrentMethod();
Set<String> toPush = new LinkedHashSet<>();
- Iterator<String> iter = bitstreams.iterator();
+ Iterator<Object[]> iter = bitstreams.iterator();
for (int i = 0; i < bitstreams.size(); i++) {
@@ -401,9 +438,15 @@
break;
}
- String p = iter.next();
+ String p = (String) iter.next()[1];
Map<String, Boolean> decoderCapabilities;
decoderCapabilities = preparer.getDecoderCapabilitiesForPath(p);
+ if (decoderCapabilities.isEmpty()) {
+ addConformanceEntry(
+ curMethod, p,
+ MediaBitstreams.K_UNAVAILABLE,
+ MediaBitstreams.K_UNSUPPORTED);
+ }
for (Entry<String, Boolean> entry : decoderCapabilities.entrySet()) {
Boolean supported = entry.getValue();
if (supported) {
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp8BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp8BitstreamsTest.java
new file mode 100644
index 0000000..e7a6cec
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp8BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class Vp8BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("vp8");
+ }
+
+ public Vp8BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv420BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv420BitstreamsTest.java
new file mode 100644
index 0000000..dde31b8
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv420BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class Vp9Yuv420BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("vp9/yuv420");
+ }
+
+ public Vp9Yuv420BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv422BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv422BitstreamsTest.java
new file mode 100644
index 0000000..a04aca4
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv422BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class Vp9Yuv422BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("vp9/yuv422");
+ }
+
+ public Vp9Yuv422BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}
diff --git a/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv444BitstreamsTest.java b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv444BitstreamsTest.java
new file mode 100644
index 0000000..dadd1c9
--- /dev/null
+++ b/hostsidetests/media/bitstreams/src/android/media/cts/bitstreams/Vp9Yuv444BitstreamsTest.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2017 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package android.media.cts.bitstreams;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized.Parameters;
+import org.junit.runners.Parameterized.UseParametersRunnerFactory;
+
+@RunWith(DeviceJUnit4Parameterized.class)
+@UseParametersRunnerFactory(DeviceJUnit4ClassRunnerWithParameters.RunnerFactory.class)
+public class Vp9Yuv444BitstreamsTest extends MediaBitstreamsTest {
+
+ @Parameters(name = "{1}")
+ public static Iterable<Object[]> bitstreams() {
+ return MediaBitstreamsTest.bitstreams("vp9/yuv444");
+ }
+
+ public Vp9Yuv444BitstreamsTest(String prefix, String path) {
+ super(prefix, path);
+ }
+
+}