]>
Commit | Line | Data |
---|---|---|
ab670ada | 1 | pkgs: { |
69619e0b SW |
2 | name = "qemu-private-store-mount-grep"; |
3 | ||
ab670ada SW |
4 | hostPkgs = pkgs; |
5 | ||
47cb654f SW |
6 | includeTestScriptReferences = false; |
7 | ||
69619e0b SW |
8 | nodes = { |
9 | shared = _: { }; | |
10 | private = _: { imports = [ ../modules/qemu-vm-isolation.nix ]; }; | |
f78c24af SW |
11 | privateErofs = _: { |
12 | imports = [ ../modules/qemu-vm-isolation.nix ]; | |
13 | virtualisation.qemu.isolation.nixStoreFilesystemType = "erofs"; | |
14 | }; | |
0fb3685a SW |
15 | useNixStoreImage = { |
16 | virtualisation = { | |
ab670ada | 17 | sharedDirectories = pkgs.lib.mkForce { }; |
0fb3685a SW |
18 | useNixStoreImage = true; |
19 | }; | |
20 | }; | |
69619e0b SW |
21 | }; |
22 | ||
23 | testScript = '' | |
24 | start_all() | |
f78c24af | 25 | for machine in [shared, private, privateErofs, useNixStoreImage]: |
620470ea | 26 | machine.wait_for_unit("multi-user.target") |
69619e0b SW |
27 | |
28 | shared.succeed("[[ $(mount | grep -c virt) -gt 0 ]]") | |
e1430264 | 29 | shared.succeed("[[ -e ${pkgs.pv} ]]") |
620470ea | 30 | |
f78c24af | 31 | for machine in [private, privateErofs, useNixStoreImage]: |
620470ea SW |
32 | machine.succeed("[[ $(mount | grep -c virt) -eq 0 ]]") |
33 | machine.fail("[[ -e ${pkgs.pv} ]]") | |
69619e0b SW |
34 | ''; |
35 | } |