My personal project and infrastructure archive
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
nomicon/nixos/tests/ksm.nix

22 lines
502 B

import ./make-test-python.nix ({ lib, ...} :
{
name = "ksm";
meta = with lib.maintainers; {
maintainers = [ rnhmjoj ];
};
nodes.machine = { ... }: {
imports = [ ../modules/profiles/minimal.nix ];
hardware.ksm.enable = true;
hardware.ksm.sleep = 300;
};
testScript =
''
machine.start()
machine.wait_until_succeeds("test $(</sys/kernel/mm/ksm/run) -eq 1")
machine.wait_until_succeeds("test $(</sys/kernel/mm/ksm/sleep_millisecs) -eq 300")
'';
})