Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions android_env/components/adb_call_parser_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
from android_env.components import adb_call_parser
from android_env.components import adb_controller
from android_env.proto import adb_pb2
from google.protobuf import text_format


class AdbCallParserTest(parameterized.TestCase):
Expand Down Expand Up @@ -229,8 +230,9 @@ def test_grant_permissions_successful(self):
def test_press_button_invalid_button(self):
adb = mock.create_autospec(adb_controller.AdbController)
parser = adb_call_parser.AdbCallParser(adb)
request = adb_pb2.AdbRequest()
request.press_button.button = 99999 # pyrefly: ignore[bad-assignment]
request = text_format.Parse(
'press_button { button: 99999 }', adb_pb2.AdbRequest()
)
response = parser.parse(request)
self.assertEqual(response.status,
adb_pb2.AdbResponse.Status.FAILED_PRECONDITION)
Expand Down
Loading