Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fc4e54ec authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "adb: fix abb test."

parents 3b55f757 8f83498c
Loading
Loading
Loading
Loading
+7 −4
Original line number Original line Diff line number Diff line
@@ -82,10 +82,13 @@ class DeviceTest(unittest.TestCase):


class AbbTest(DeviceTest):
class AbbTest(DeviceTest):
    def test_smoke(self):
    def test_smoke(self):
        result = subprocess.run(['adb', 'abb'], capture_output=True)
        abb = subprocess.run(['adb', 'abb'], capture_output=True)
        self.assertEqual(1, result.returncode)
        cmd = subprocess.run(['adb', 'shell', 'cmd'], capture_output=True)
        expected_output = b"cmd: No service specified; use -l to list all services\n"

        self.assertEqual(expected_output, result.stderr)
        # abb squashes all failures to 1.
        self.assertEqual(abb.returncode == 0, cmd.returncode == 0)
        self.assertEqual(abb.stdout, cmd.stdout)
        self.assertEqual(abb.stderr, cmd.stderr)


class ForwardReverseTest(DeviceTest):
class ForwardReverseTest(DeviceTest):
    def _test_no_rebind(self, description, direction_list, direction,
    def _test_no_rebind(self, description, direction_list, direction,