From dfa743e49e45bcb6d334e50f24275b04a004a6f6 Mon Sep 17 00:00:00 2001 From: Erik Arvstedt Date: Wed, 27 May 2020 22:07:42 +0200 Subject: [PATCH] test-driver: remove useless syncs These syncs have the goal to transfer host filesystem changes to the VM, but they have no effect because 1) syncing in the VM can't possibly pull in host data and 2) 9p is accessing the host filesystem on the cached layer anyways, so even syncing on the host would have no effect in the VM. --- nixos/lib/test-driver/test-driver.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/nixos/lib/test-driver/test-driver.py b/nixos/lib/test-driver/test-driver.py index c27947bc610d..ff6d763989f5 100644 --- a/nixos/lib/test-driver/test-driver.py +++ b/nixos/lib/test-driver/test-driver.py @@ -596,11 +596,8 @@ class Machine: shutil.copytree(host_src, host_intermediate) else: shutil.copy(host_src, host_intermediate) - self.succeed("sync") self.succeed(make_command(["mkdir", "-p", vm_target.parent])) self.succeed(make_command(["cp", "-r", vm_intermediate, vm_target])) - # Make sure the cleanup is synced into VM - self.succeed("sync") def copy_from_vm(self, source: str, target_dir: str = "") -> None: """Copy a file from the VM (specified by an in-VM source path) to a path @@ -626,8 +623,6 @@ class Machine: shutil.copytree(intermediate, abs_target) else: shutil.copy(intermediate, abs_target) - # Make sure the cleanup is synced into VM - self.succeed("sync") def dump_tty_contents(self, tty: str) -> None: """Debugging: Dump the contents of the TTY