-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding ability to run adb reverse in mobly, fixes #900 #901
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @ssachinsunder and @xpconanfan)
tests/mobly/controllers/android_device_lib/adb_test.py
line 634 at r1 (raw file):
def test_reverse(self): with mock.patch.object(adb.AdbProxy, '_exec_cmd') as mock_exec_cmd: adb.AdbProxy().reverse(MOCK_SHELL_COMMAND)
Add an assertion to check that correct arguments are passed to _exec_cmd?
Code quote:
adb.AdbProxy().reverse(MOCK_SHELL_COMMAND)
Updated the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 0 of 2 files reviewed, 2 unresolved discussions (waiting on @mhaoli, @ssachinsunder, and @xpconanfan)
tests/mobly/controllers/android_device_lib/adb_test.py
line 634 at r1 (raw file):
Previously, mhaoli (Minghao Li) wrote…
Add an assertion to check that correct arguments are passed to _exec_cmd?
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 2 files at r1, all commit messages.
Reviewable status: 1 of 2 files reviewed, 4 unresolved discussions (waiting on @ssachinsunder and @xpconanfan)
tests/mobly/controllers/android_device_lib/adb_test.py
line 630 at r3 (raw file):
def test_forward(self): with mock.patch.object(adb.AdbProxy, '_exec_cmd') as mock_exec_cmd: adb.AdbProxy().forward(MOCK_SHELL_COMMAND)
Thanks for updating the test case test_forward.
How about using args that are similiar to real forward command and reverse command in the test cases?
e.g.
adb.AdbProxy().forward(['tcp:12345', 'tcp:23456'])
adb.AdbProxy().reverse(['tcp:12345', 'tcp:23456'])
Code quote:
MOCK_SHELL_COMMAND
tests/mobly/controllers/android_device_lib/adb_test.py
line 638 at r3 (raw file):
def test_reverse(self): with mock.patch.object(adb.AdbProxy, '_exec_cmd') as mock_exec_cmd: adb.AdbProxy().reverse(MOCK_SHELL_COMMAND)
ditto here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 1 of 2 files reviewed, 4 unresolved discussions (waiting on @mhaoli and @xpconanfan)
tests/mobly/controllers/android_device_lib/adb_test.py
line 630 at r3 (raw file):
Previously, mhaoli (Minghao Li) wrote…
Thanks for updating the test case test_forward.
How about using args that are similiar to real forward command and reverse command in the test cases?
e.g.
adb.AdbProxy().forward(['tcp:12345', 'tcp:23456'])
adb.AdbProxy().reverse(['tcp:12345', 'tcp:23456'])
Done.
tests/mobly/controllers/android_device_lib/adb_test.py
line 638 at r3 (raw file):
Previously, mhaoli (Minghao Li) wrote…
ditto here
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r4, all commit messages.
Reviewable status: all files reviewed, 4 unresolved discussions (waiting on @xpconanfan)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @xpconanfan)
Please rebase and resolve the conflict so we can merge |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like there was a switch in py formatting tool. How do I use the new tool (pyink) to ensure formatting is right?
Reviewable status: 0 of 89 files reviewed, 1 unresolved discussion (waiting on @mhaoli and @xpconanfan)
3a8b525
to
ebdec3a
Compare
Sorry closed this accidentally by discarding commits via GitHub UI (didn't expect that to happen). Created a new pull request - #903 |
Adding
AdbProxy.reverse()
method to runadb reverse
via Mobly framework.This change is