mirror of
https://github.com/nix-community/disko.git
synced 2026-11-30 21:13:28 +01:00
tests: cover detached LUKS headers
This commit is contained in:
1 parent
ff8702b4de
commit
2dfbf0dcb0
2 files changed
+57
No files matched your search
@@ -0,0 +1,17 @@
|
||||
{
|
||||
pkgs ? import <nixpkgs> { },
|
||||
diskoLib ? pkgs.callPackage ../lib { },
|
||||
}:
|
||||
diskoLib.testLib.makeDiskoTest {
|
||||
inherit pkgs;
|
||||
name = "luks-detached-header";
|
||||
disko-config = ../example/luks-detached-header.nix;
|
||||
testMode = "direct";
|
||||
testBoot = false;
|
||||
extraTestScript = ''
|
||||
machine.succeed("${pkgs.cryptsetup}/bin/cryptsetup isLuks /dev/disk/by-partlabel/disk-main-luks-header");
|
||||
machine.fail("${pkgs.cryptsetup}/bin/cryptsetup isLuks /dev/disk/by-partlabel/disk-main-crypt");
|
||||
machine.succeed("mountpoint /mnt");
|
||||
machine.succeed("test -e /mnt/home/testfile");
|
||||
'';
|
||||
}
|
||||
Reference in new issue
Block a user