Commit 58eb7836 authored by Scott Stephens's avatar Scott Stephens
Browse files

nixos/tpm2: move tpm2 tests to own directory

parent d786a9f8
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1633,7 +1633,7 @@ in
  tomcat = runTest ./tomcat.nix;
  tor = runTest ./tor.nix;
  tpm-ek = handleTest ./tpm-ek { };
  tpm2 = runTest ./tpm2.nix;
  tpm2 = import ./tpm2 { inherit runTest; };
  traccar = runTest ./traccar.nix;
  # tracee requires bpf
  tracee = handleTestOn [ "x86_64-linux" ] ./tracee.nix { };
+4 −0
Original line number Diff line number Diff line
{ runTest }:
{
  abrmd = runTest ./tpm2-abrmd.nix;
}
+4 −0
Original line number Diff line number Diff line
@@ -39,6 +39,10 @@
    machine.start()
    machine.wait_for_unit("multi-user.target")

    with subtest("/dev/tpmrm0 has correct ownership"):
        machine.succeed('[ `stat -c "%U" /dev/tpmrm0` = "tss" ]')
        machine.succeed('[ `stat -c "%G" /dev/tpmrm0` = "tss" ]')

    with subtest("tabrmd service started properly"):
        machine.succeed('[ `systemctl show tpm2-abrmd.service --property=Result` = "Result=success" ]')
        machine.succeed('[ `journalctl -b -u tpm2-abrmd.service | grep -c "Starting"` = "1" ]')