nixos/tests/wine: Test all five wine variants
This commit is contained in:
parent
aa845c3100
commit
2690ab613b
1 changed files with 25 additions and 12 deletions
|
@ -1,14 +1,27 @@
|
||||||
import ./make-test-python.nix ({ pkgs, ... }: {
|
{ system ? builtins.currentSystem, pkgs ? import ../.. {
|
||||||
name = "wine";
|
inherit system;
|
||||||
meta = with pkgs.lib.maintainers; { maintainers = [ chkno ]; };
|
config = { };
|
||||||
|
}, }:
|
||||||
|
|
||||||
machine = { pkgs, ... }: { environment.systemPackages = [ pkgs.wine ]; };
|
let
|
||||||
|
inherit (import ../lib/testing-python.nix { inherit system pkgs; }) makeTest;
|
||||||
|
|
||||||
testScript = ''
|
makeWineTest = variant:
|
||||||
machine.wait_for_unit("multi-user.target")
|
makeTest {
|
||||||
greeting = machine.succeed(
|
name = "wine-${variant}";
|
||||||
'wine ${pkgs.pkgsCross.mingw32.hello}/bin/hello.exe'
|
meta = with pkgs.lib.maintainers; { maintainers = [ chkno ]; };
|
||||||
)
|
|
||||||
assert 'Hello, world!' in greeting
|
machine = { pkgs, ... }: {
|
||||||
'';
|
environment.systemPackages = [ pkgs.winePackages."${variant}" ];
|
||||||
})
|
};
|
||||||
|
|
||||||
|
testScript = ''
|
||||||
|
machine.wait_for_unit("multi-user.target")
|
||||||
|
greeting = machine.succeed(
|
||||||
|
'wine ${pkgs.pkgsCross.mingw32.hello}/bin/hello.exe'
|
||||||
|
)
|
||||||
|
assert 'Hello, world!' in greeting
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
in pkgs.lib.genAttrs [ "base" "full" "minimal" "staging" "unstable" ]
|
||||||
|
makeWineTest
|
||||||
|
|
Loading…
Reference in a new issue