[CTS_9.0]CtsMedia相关module测试fail原因

[DESCRIPTION]

 run Test Report

CtsMediaStressTestCases

 run Test Report

CtsMediaTestCases
[SOLUTION]

 Test Report

android.mediastress.cts.H263QcifLongPlayerTest#testPlay00
fail
java.lang.AssertionError: Remote connection to DynamicConfigService required for this test at org.junit.Assert.fail(Assert.java:88) at org.junit.Assert.assertTrue

报” Remote connection to DynamicConfigService required for this test”

是CTS 9.0_r2这个包才出现的问题:

1、Linux fail的原因是workstation不能连外网,因此需要连接翻墙网络!

2、Windows fail的原因是缺少完善的启动脚本 ,如果要用windows环境验证,可参考方法如下:

1、自己的PC安装Git-2.19.0-64-bit.exe

2、进入CTS对应的android-cts/tools folder, 右键->git bash here

3、修改tool文件夹的cts-tradefed脚本,把exit替换为OS=”linux-x86″,保存

# get OS

HOST=uname

if [ “$HOST” == “Linux” ]; then

OS=”linux-x86″

elif [ “$HOST” == “Darwin” ]; then

OS=”darwin-x86″

else

echo “Unrecognized OS”

exit

fi

# get OS

HOST=uname

if [ “$HOST” == “Linux” ]; then

OS=”linux-x86″

elif [ “$HOST” == “Darwin” ]; then

OS=”darwin-x86″

else

echo “Unrecognized OS”

OS=”linux-x86″

fi

  1. $ ./cts-tradefed run cts -m CtsMediaStressTestCases -t android.mediastress.cts.H263QcifShortPlayerTest#testPlay00git bash窗口输入./cts-tradefed + 测试指令,g.

微信扫码打赏

作者: RESSRC

个人资源站

《[CTS_9.0]CtsMedia相关module测试fail原因》有3个想法

  1. 12-12 23:52:28 D/SystemServerFileDescriptorChecker: Skipping system_server fd check on user builds.
    12-12 23:52:28 I/ITestSuite: Running system status checker before module execution: arm64-v8a CtsMediaStressTestCases
    12-12 23:52:28 D/ModuleDefinition: Running module arm64-v8a CtsMediaStressTestCases
    12-12 23:52:28 D/ModuleDefinition: Preparer: DynamicConfigPusher
    12-12 23:54:35 D/ddms: Reading file permision of /tmp/CtsMediaStressTestCases6212638735339600058.dynamic as: rw-rw-r–
    12-12 23:54:35 D/ModuleDefinition: Preparer: MediaPreparer
    12-12 23:54:36 D/CtsMediaPreparerApp.apk: Uploading CtsMediaPreparerApp.apk onto device ’36e7881e’
    12-12 23:54:36 D/Device: Uploading file onto device ’36e7881e’
    12-12 23:54:36 D/ddms: Reading file permision of /home/test/CTS/9.0R4/android-cts/tools/../../android-cts/testcases/CtsMediaPreparerApp.apk as: rw-rw-r–
    12-12 23:54:38 D/InstrumentationTest: Collecting test info for android.mediastress.cts.preconditions.app on device 36e7881e
    12-12 23:54:38 I/RemoteAndroidTest: Running am instrument -w -r -e debug false -e newRunListenerMode true -e log true -e timeout_msec 300000 android.mediastress.cts.preconditions.app/android.support.test.runner.AndroidJUnitRunner on blackshark-skywalker-36e7881e
    12-12 23:54:39 I/RemoteAndroidTest: Running am instrument -w -r -e debug false -e newRunListenerMode true -e log false -e timeout_msec 300000 android.mediastress.cts.preconditions.app/android.support.test.runner.AndroidJUnitRunner on blackshark-skywalker-36e7881e
    12-12 23:54:40 D/TestDevice: Uninstalling android.mediastress.cts.preconditions.app
    12-12 23:54:41 E/TestInvocation: Caught AssertionError while running invocation: java.lang.AssertionError: Remote connection to DynamicConfigService required for this test
    12-12 23:54:41 E/TestInvocation: Remote connection to DynamicConfigService required for this test
    java.lang.AssertionError: Remote connection to DynamicConfigService required for this test
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.assertTrue(Assert.java:41)
    at com.android.compatibility.common.util.DynamicConfig.assertRemoteConfigRequirementMet(DynamicConfig.java:93)
    at com.android.compatibility.common.util.DynamicConfig.getValue(DynamicConfig.java:59)
    at com.android.compatibility.common.tradefed.util.DynamicConfigFileReader.getValueFromConfig(DynamicConfigFileReader.java:46)
    at com.android.compatibility.common.tradefed.util.DynamicConfigFileReader.getValueFromConfig(DynamicConfigFileReader.java:80)
    at com.android.compatibility.common.tradefed.targetprep.MediaPreparer.downloadMediaToHost(MediaPreparer.java:230)
    at com.android.compatibility.common.tradefed.targetprep.MediaPreparer.run(MediaPreparer.java:340)
    at com.android.compatibility.common.tradefed.targetprep.PreconditionPreparer.setUp(PreconditionPreparer.java:65)
    at com.android.tradefed.testtype.suite.ModuleDefinition.runPreparerSetup(ModuleDefinition.java:599)
    at com.android.tradefed.testtype.suite.ModuleDefinition.run(ModuleDefinition.java:309)
    at com.android.tradefed.testtype.suite.ITestSuite.runSingleModule(ITestSuite.java:509)
    at com.android.tradefed.testtype.suite.ITestSuite.run(ITestSuite.java:438)
    at com.android.tradefed.invoker.shard.TestsPoolPoller.run(TestsPoolPoller.java:142)
    at com.android.tradefed.invoker.InvocationExecution.runTests(InvocationExecution.java:376)
    at com.android.tradefed.invoker.TestInvocation.prepareAndRun(TestInvocation.java:358)
    at com.android.tradefed.invoker.TestInvocation.performInvocation(TestInvocation.java:205)
    at com.android.tradefed.invoker.TestInvocation.invoke(TestInvocation.java:667)
    at com.android.tradefed.command.CommandScheduler$InvocationThread.run(CommandScheduler.java:566)

    碰到一个类似的case,是需要下载https://dl.google.com/dl/android/cts/android-cts-media-1.4.zip文件,没有连接vpn,导致下载失败,cts也停止

    1. 博主好,是电脑没连接vpn还是测试手机没有连接vpn呢?我这边电脑和手机都连接vpn,还是报这个错,有什么解决办法不?

发表评论

电子邮件地址不会被公开。 必填项已用*标注

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据