Remove extra quotes around adb.shell args.
aosp/748370 changes behavior of adb.shell cmd, which breaks some the
test cases. Remove extra quotes to fix.
Fixes: 118499847
Test: vts-tradefed run commandAndExit vts --skip-all-system-status-check
--primary-abi-only --skip-preconditions --skip-device-info --module
VtsKernelProcFileApi
Change-Id: I3c7da3ea3305986c5ca221f6419d700289240ad5
diff --git a/api/proc/VtsKernelProcFileApiTest.py b/api/proc/VtsKernelProcFileApiTest.py
index 9c472d8..a656b37 100644
--- a/api/proc/VtsKernelProcFileApiTest.py
+++ b/api/proc/VtsKernelProcFileApiTest.py
@@ -206,16 +206,16 @@
# This command only performs a best effort attempt to remount all
# filesystems. Check that it doesn't throw an error.
- self.dut.adb.shell("\"echo u > %s\"" % filepath)
+ self.dut.adb.shell("echo u > %s" % filepath)
# Reboot the device.
- self.dut.adb.shell("\"echo b > %s\"" % filepath)
+ self.dut.adb.shell("echo b > %s" % filepath)
asserts.assertFalse(self.dut.hasBooted(), "Device is still alive.")
self.dut.waitForBootCompletion()
self.dut.rootAdb()
# Crash the system.
- self.dut.adb.shell("\"echo c > %s\"" % filepath)
+ self.dut.adb.shell("echo c > %s" % filepath)
asserts.assertFalse(self.dut.hasBooted(), "Device is still alive.")
self.dut.waitForBootCompletion()
self.dut.rootAdb()
@@ -232,7 +232,7 @@
"""
stats_path = "/proc/uid_io/stats"
result = self.dut.adb.shell(
- "\"cat %s | grep '^%d'\"" % (stats_path, uid),
+ "cat %s | grep '^%d'" % (stats_path, uid),
no_except=True)
return result[const.STDOUT].split()
@@ -250,9 +250,9 @@
# fg write chars are at index 2, and bg write chars are at 6.
wchar_index = 6 if state else 2
old_wchar = UidIOStats(root_uid)[wchar_index]
- self.dut.adb.shell("\"echo %d %s > %s\"" % (root_uid, state, filepath))
+ self.dut.adb.shell("echo %d %s > %s" % (root_uid, state, filepath))
# This should increase the number of write syscalls.
- self.dut.adb.shell("\"echo foo\"")
+ self.dut.adb.shell("echo foo")
asserts.assertLess(
old_wchar,
UidIOStats(root_uid)[wchar_index],