mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
tests: Fix clippy issue related to unnecessary use of .to_string()
error: unnecessary use of `to_string`
--> cloud-hypervisor/tests/integration.rs:6765:38
|
6765 | exec_host_command_output(&"sudo dd if=/dev/zero of=/tmp/resize.img bs=1M count=16".to_string())
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use: `"sudo dd if=/dev/zero of=/tmp/resize.img bs=1M count=16"`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned
= note: `-D clippy::unnecessary-to-owned` implied by `-D clippy::all`
= help: to override `-D clippy::all` add `#[allow(clippy::unnecessary_to_owned)]`
Signed-off-by: Rob Bradford <rbradford@meta.com>
This commit is contained in:
@@ -6762,11 +6762,9 @@ mod common_parallel {
|
||||
|
||||
// Create a disk image that we can write to
|
||||
assert!(
|
||||
exec_host_command_output(
|
||||
&"sudo dd if=/dev/zero of=/tmp/resize.img bs=1M count=16".to_string()
|
||||
)
|
||||
.status
|
||||
.success()
|
||||
exec_host_command_output("sudo dd if=/dev/zero of=/tmp/resize.img bs=1M count=16")
|
||||
.status
|
||||
.success()
|
||||
);
|
||||
|
||||
let mut cmd = GuestCommand::new(&guest);
|
||||
|
||||
Reference in New Issue
Block a user