最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

FLUTTER Android TV App CTS Media Session Manager Test Failed - Stack Overflow

programmeradmin2浏览0评论

We developed an Android TV launcher application using Flutter. However, during the Compatibility Test Suite (CTS) validation process, the MediaSessionManagerTest-related tests repeatedly failed. Several attempts have been made to analyze and resolve the cause of the problem, but we are having difficulty identifying the exact cause.

When I made an empty project with Android Studio and tested it by changing the manifest to Korean, it passed the test, and when I made a project with flutter in the same way and tested it, the error comes out, does anyone know that part?

  1. I would like to know if there are any settings or requirements needed to pass the test on the Flutter-based Android TV app
  2. If you have any known issues or workarounds related to that test, please share them.

flutter version : 3.29.0 cts version : android-cts-14_r7-linux_x86-arm minSdk = 28 targetSdk = 34

Successful logcat

03-07 15:59:20.704  9423  9443 V CtsSystemUtil: Running command: input keyevent 79
03-07 15:59:20.712   764   764 D BatterySaverPolicy: accessibility changed to true, updating policy.
03-07 15:59:20.716  9423  9443 I System.out: JNI not loaded
03-07 15:59:20.729   420  1666 D rtk_heartbeat: heartbeat_timed_out: heartbeatCmdCount = 465, expected nextSeqNum = 465
03-07 15:59:20.730   420  1547 D rtk_heartbeat: rtkbt_heartbeat_cmpl_cback: Current SeqNum = 465,should SeqNum=465, status = 0
03-07 15:59:20.733  6454  6454 E Clearcut-EventLogger: Unexpected log parameter tray_notification_count
03-07 15:59:20.785   764  2128 D MediaSessionService: Send KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_HEADSETHOOK, scanCode=0, metaState=0, flags=0x0, repeatCount=0, eventTime=560249000000, downTime=560249000000, deviceId=-1, source=0x0, displayId=-1 } to the media key listener
03-07 15:59:20.789   764  2128 D MediaSessionService: Send KeyEvent { action=ACTION_UP, keyCode=KEYCODE_HEADSETHOOK, scanCode=0, metaState=0, flags=0x0, repeatCount=0, eventTime=560249000000, downTime=560249000000, deviceId=-1, source=0x0, displayId=-1 } to the media key listener

Failed flutter logcat

03-14 14:22:22.120  9766  9785 V CtsSystemUtil: Running command: input keyevent 79
03-14 14:22:22.134  1436  1436 I MediaPlayerList: sendMediaUpdate: Creating a one item queue for a player with no queue
03-14 14:22:22.135  1436  1436 D MediaPlayerList: sendMediaUpdate state=PlaybackState {state=PLAYING(3), position=608, buffered position=0, speed=1.0, updated=750214, actions=0, custom actions=[], active item id=-1, error=null}
03-14 14:22:22.135  1436  1436 D AvrcpTargetJni: sendMediaUpdateNative
03-14 14:22:22.135  1436  1436 I bt_stack: [INFO:avrcp_service(515)] virtual void bluetooth::avrcp::AvrcpService::SendMediaUpdate(bool, bool, bool) track_changed=0 :  play_state=0 :  queue=0
03-14 14:22:22.145   794   828 I dvm_lock_sample: [system_server,1,ActivityManager,7,BroadcastQueueModernImpl.java,293,boolean com.android.server.am.BroadcastQueueModernImpl.lambda$new$0(android.os.Message),ActivityManagerService.java,13424,int com.android.server.am.ActivityManagerService.bindServiceInstance(android.app.IApplicationThread, android.os.IBinder, android.content.Intent, java.lang.String, android.app.IServiceConnection, long, java.lang.String, boolean, int, java.lang.String, android.app.IApplicationThread, java.lang.String, int),1]
03-14 14:22:22.148  9766  9785 I System.out: JNI not loaded
03-14 14:22:22.224  5064  5064 I HAMA_DEBUG: dispatchKeyEvent : KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_HEADSETHOOK, scanCode=0, metaState=0, flags=0x0, repeatCount=0, eventTime=750299000000, downTime=750299000000, deviceId=-1, source=0x0, displayId=-1 }
03-14 14:22:22.228  5064  5064 I HAMA_DEBUG: dispatchKeyEvent : KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_HEADSETHOOK, scanCode=0, metaState=0, flags=0x0, repeatCount=0, eventTime=750299000000, downTime=750299000000, deviceId=-1, source=0x0, displayId=-1 }
03-14 14:22:22.231  5064  5064 I HAMA_DEBUG: dispatchKeyEvent : KeyEvent { action=ACTION_UP, keyCode=KEYCODE_HEADSETHOOK, scanCode=0, metaState=0, flags=0x0, repeatCount=0, eventTime=750299000000, downTime=750299000000, deviceId=-1, source=0x0, displayId=-1 }
03-14 14:22:22.234  5064  5064 I HAMA_DEBUG: dispatchKeyEvent : KeyEvent { action=ACTION_UP, keyCode=KEYCODE_HEADSETHOOK, scanCode=0, metaState=0, flags=0x200, repeatCount=0, eventTime=750299000000, downTime=750299000000, deviceId=-1, source=0x0, displayId=-1 }


03-14 14:22:25.282  9766  9781 E TestRunner: expected to be true
03-14 14:22:25.282  9766  9781 E TestRunner: at android.media.bettertogether.cts.MediaSessionManagerTest.testSetOnMediaKeyListener(MediaSessionManagerTest.java:380)
发布评论

评论列表(0)

  1. 暂无评论