Skip to content

Commit

Permalink
nixos/tests/gdk-pixbuf: fix test on i686 (#46916)
Browse files Browse the repository at this point in the history
Test didn't run because it tried to create a VM with 4096M RAM
but qemu-system-i386 has a hard 2047M memory limit.
- reduce memory to 2047M on i686.
- increase timeout 300s -> 1800s because the tests are much slower
  on i686 and timed out.
  • Loading branch information
xeji committed Sep 20, 2018
1 parent 9114d13 commit e40d850
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions nixos/tests/gdk-pixbuf.nix
Expand Up @@ -10,10 +10,12 @@ import ./make-test.nix ({ pkgs, ... }: {
environment.systemPackages = with pkgs; [ gnome-desktop-testing ];
environment.variables.XDG_DATA_DIRS = [ "${pkgs.gdk_pixbuf.installedTests}/share" ];

virtualisation.memorySize = 4096; # Tests allocate a lot of memory trying to exploit a CVE
# Tests allocate a lot of memory trying to exploit a CVE
# but qemu-system-i386 has a 2047M memory limit
virtualisation.memorySize = if pkgs.stdenv.isi686 then 2047 else 4096;
};

testScript = ''
$machine->succeed("gnome-desktop-testing-runner");
$machine->succeed("gnome-desktop-testing-runner -t 1800"); # increase timeout to 1800s
'';
})

0 comments on commit e40d850

Please sign in to comment.