Loading android/pandora/mmi2grpc/mmi2grpc/sm.py +31 −3 Original line number Diff line number Diff line Loading @@ -24,6 +24,17 @@ NEEDS_PAIRING_CONFIRMATION = { "SM/CEN/EKS/BV-01-C", "SM/CEN/JW/BI-04-C", "SM/CEN/JW/BI-01-C", "SM/CEN/KDU/BV-04-C", "SM/CEN/KDU/BV-05-C", "SM/CEN/KDU/BV-06-C", "SM/CEN/KDU/BV-10-C", "SM/CEN/KDU/BV-11-C", } ACCEPTS_REMOTE_PAIRING_CONFIRMATION = { "SM/CEN/KDU/BI-01-C", "SM/CEN/KDU/BI-02-C", "SM/CEN/KDU/BI-03-C", } Loading @@ -36,11 +47,13 @@ class SMProxy(ProfileProxy): self.connection = None @assert_description def MMI_IUT_ENABLE_CONNECTION_SM(self, pts_addr: bytes, **kwargs): def MMI_IUT_ENABLE_CONNECTION_SM(self, test, pts_addr: bytes, **kwargs): """ Initiate an connection from the IUT to the PTS. """ self.connection = self.host.ConnectLE(address=pts_addr).connection if self.connection and test in ACCEPTS_REMOTE_PAIRING_CONFIRMATION: self.sm.ProvidePairingConfirmation(connection=self.connection, pairing_confirmation_value=True) return "OK" @assert_description Loading Loading @@ -68,3 +81,18 @@ class SMProxy(ProfileProxy): self.host.DisconnectLE(connection=self.connection) self.connection = None return "OK" def MMI_LESC_NUMERIC_COMPARISON(self, **kwargs): """ Please confirm the following number matches IUT: 385874. """ return "OK" @assert_description def MMI_ASK_IUT_PERFORM_RESET(self, **kwargs): """ Please reset your device. """ self.host.Reset() return "OK" android/pandora/server/configs/PtsBotTest.xml +2 −0 Original line number Diff line number Diff line Loading @@ -32,5 +32,7 @@ <option name="profile" value="SDP/SR" /> <option name="profile" value="SM/CEN/EKS" /> <option name="profile" value="SM/CEN/JW" /> <option name="profile" value="SM/CEN/KDU" /> </test> </configuration> android/pandora/server/configs/pts_bot_tests_config.json +9 −1 Original line number Diff line number Diff line Loading @@ -102,7 +102,15 @@ "SM/CEN/EKS/BV-01-C", "SM/CEN/JW/BI-01-C", "SM/CEN/JW/BI-04-C", "SM/CEN/JW/BV-05-C" "SM/CEN/JW/BV-05-C", "SM/CEN/KDU/BI-01-C", "SM/CEN/KDU/BV-04-C", "SM/CEN/KDU/BV-05-C", "SM/CEN/KDU/BI-02-C", "SM/CEN/KDU/BV-06-C", "SM/CEN/KDU/BV-10-C", "SM/CEN/KDU/BI-03-C", "SM/CEN/KDU/BV-11-C" ], "skip": [ "A2DP/SRC/AS/BV-01-I", Loading android/pandora/server/src/com/android/pandora/GattInstance.kt +0 −1 Original line number Diff line number Diff line Loading @@ -122,7 +122,6 @@ class GattInstance(val mDevice: BluetoothDevice, val mTransport: Int, val mConte require(isConnected()) { "Trying to disconnect an already disconnected device $mDevice" } mGatt.close() mGatt.disconnect() gattInstances.remove(mDevice.address) } Loading Loading
android/pandora/mmi2grpc/mmi2grpc/sm.py +31 −3 Original line number Diff line number Diff line Loading @@ -24,6 +24,17 @@ NEEDS_PAIRING_CONFIRMATION = { "SM/CEN/EKS/BV-01-C", "SM/CEN/JW/BI-04-C", "SM/CEN/JW/BI-01-C", "SM/CEN/KDU/BV-04-C", "SM/CEN/KDU/BV-05-C", "SM/CEN/KDU/BV-06-C", "SM/CEN/KDU/BV-10-C", "SM/CEN/KDU/BV-11-C", } ACCEPTS_REMOTE_PAIRING_CONFIRMATION = { "SM/CEN/KDU/BI-01-C", "SM/CEN/KDU/BI-02-C", "SM/CEN/KDU/BI-03-C", } Loading @@ -36,11 +47,13 @@ class SMProxy(ProfileProxy): self.connection = None @assert_description def MMI_IUT_ENABLE_CONNECTION_SM(self, pts_addr: bytes, **kwargs): def MMI_IUT_ENABLE_CONNECTION_SM(self, test, pts_addr: bytes, **kwargs): """ Initiate an connection from the IUT to the PTS. """ self.connection = self.host.ConnectLE(address=pts_addr).connection if self.connection and test in ACCEPTS_REMOTE_PAIRING_CONFIRMATION: self.sm.ProvidePairingConfirmation(connection=self.connection, pairing_confirmation_value=True) return "OK" @assert_description Loading Loading @@ -68,3 +81,18 @@ class SMProxy(ProfileProxy): self.host.DisconnectLE(connection=self.connection) self.connection = None return "OK" def MMI_LESC_NUMERIC_COMPARISON(self, **kwargs): """ Please confirm the following number matches IUT: 385874. """ return "OK" @assert_description def MMI_ASK_IUT_PERFORM_RESET(self, **kwargs): """ Please reset your device. """ self.host.Reset() return "OK"
android/pandora/server/configs/PtsBotTest.xml +2 −0 Original line number Diff line number Diff line Loading @@ -32,5 +32,7 @@ <option name="profile" value="SDP/SR" /> <option name="profile" value="SM/CEN/EKS" /> <option name="profile" value="SM/CEN/JW" /> <option name="profile" value="SM/CEN/KDU" /> </test> </configuration>
android/pandora/server/configs/pts_bot_tests_config.json +9 −1 Original line number Diff line number Diff line Loading @@ -102,7 +102,15 @@ "SM/CEN/EKS/BV-01-C", "SM/CEN/JW/BI-01-C", "SM/CEN/JW/BI-04-C", "SM/CEN/JW/BV-05-C" "SM/CEN/JW/BV-05-C", "SM/CEN/KDU/BI-01-C", "SM/CEN/KDU/BV-04-C", "SM/CEN/KDU/BV-05-C", "SM/CEN/KDU/BI-02-C", "SM/CEN/KDU/BV-06-C", "SM/CEN/KDU/BV-10-C", "SM/CEN/KDU/BI-03-C", "SM/CEN/KDU/BV-11-C" ], "skip": [ "A2DP/SRC/AS/BV-01-I", Loading
android/pandora/server/src/com/android/pandora/GattInstance.kt +0 −1 Original line number Diff line number Diff line Loading @@ -122,7 +122,6 @@ class GattInstance(val mDevice: BluetoothDevice, val mTransport: Int, val mConte require(isConnected()) { "Trying to disconnect an already disconnected device $mDevice" } mGatt.close() mGatt.disconnect() gattInstances.remove(mDevice.address) } Loading