tests: Simplfy the shm region check

There is no need to spawn a subshell in this case as grep can open the
file directly.

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
Rob Bradford 2020-03-04 16:36:14 +00:00 committed by Sebastien Boeuf
parent 97affbebfe
commit 2baf5ab80d

View File

@ -691,7 +691,7 @@ mod tests {
cache_size: Option<u64>,
) -> Result<bool, Error> {
let shm_region = self
.ssh_command("sudo -E bash -c 'cat /proc/iomem' | grep virtio-pci-shm")?
.ssh_command("sudo grep virtio-pci-shm /proc/iomem")?
.trim()
.to_string();