tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
0
fork
atom
lol
0
fork
atom
overview
issues
pulls
pipelines
nixos/tests/archi: init smoke tests for Archi
paumr
2 years ago
f561320b
d4f9180a
+36
3 changed files
expand all
collapse all
unified
split
nixos
tests
all-tests.nix
archi.nix
pkgs
tools
misc
archi
default.nix
+1
nixos/tests/all-tests.nix
···
124
124
apfs = runTest ./apfs.nix;
125
125
appliance-repart-image = runTest ./appliance-repart-image.nix;
126
126
apparmor = handleTest ./apparmor.nix {};
127
127
+
archi = handleTest ./archi.nix {};
127
128
atd = handleTest ./atd.nix {};
128
129
atop = handleTest ./atop.nix {};
129
130
atuin = handleTest ./atuin.nix {};
+31
nixos/tests/archi.nix
···
1
1
+
import ./make-test-python.nix ({ lib, ... }: {
2
2
+
name = "archi";
3
3
+
meta.maintainers = with lib.maintainers; [ paumr ];
4
4
+
5
5
+
nodes.machine = { pkgs, ... }: {
6
6
+
imports = [
7
7
+
./common/x11.nix
8
8
+
];
9
9
+
10
10
+
environment.systemPackages = with pkgs; [ archi ];
11
11
+
};
12
12
+
13
13
+
enableOCR = true;
14
14
+
15
15
+
testScript = ''
16
16
+
machine.wait_for_x()
17
17
+
18
18
+
with subtest("createEmptyModel via CLI"):
19
19
+
machine.succeed("Archi -application com.archimatetool.commandline.app -consoleLog -nosplash --createEmptyModel --saveModel smoke.archimate")
20
20
+
machine.copy_from_vm("smoke.archimate", "")
21
21
+
22
22
+
with subtest("UI smoketest"):
23
23
+
machine.succeed("DISPLAY=:0 Archi --createEmptyModel >&2 &")
24
24
+
machine.wait_for_window("Archi")
25
25
+
26
26
+
# wait till main UI is open
27
27
+
machine.wait_for_text("Welcome to Archi")
28
28
+
29
29
+
machine.screenshot("welcome-screen")
30
30
+
'';
31
31
+
})
+4
pkgs/tools/misc/archi/default.nix
···
7
7
, webkitgtk
8
8
, wrapGAppsHook
9
9
, _7zz
10
10
+
, archi
11
11
+
, nixosTests
10
12
}:
11
13
12
14
stdenv.mkDerivation rec {
···
63
65
mkdir -p "$out/Applications"
64
66
mv Archi.app "$out/Applications/"
65
67
'';
68
68
+
69
69
+
passthru.tests = { inherit (nixosTests) archi; };
66
70
67
71
meta = with lib; {
68
72
description = "ArchiMate modelling toolkit";